Skip to content

Commit

Permalink
Update linting GitHub Action
Browse files Browse the repository at this point in the history
  • Loading branch information
bittremieux committed Apr 16, 2024
1 parent 86fbf26 commit 4a5da1a
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 29 deletions.
29 changes: 0 additions & 29 deletions .github/workflows/black.yml

This file was deleted.

34 changes: 34 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Lint

on:
push:
branches:
- main
- dev
pull_request:
branches:
- main
- dev

jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"

- name: Lint with black
uses: psf/black@stable
with:
options: "--check --diff --line-length 79"

- name: Check for debugging print statements
run: |
if grep -rq "print(" spectrum_utils; then
echo "Found the following print statements:"
grep -r "print(" spectrum_utils
exit 1
fi

0 comments on commit 4a5da1a

Please sign in to comment.