Skip to content

Commit

Permalink
Run all linting on one job
Browse files Browse the repository at this point in the history
  • Loading branch information
LiamPattinson committed Nov 7, 2023
1 parent 4253119 commit 53f01ab
Showing 1 changed file with 10 additions and 23 deletions.
33 changes: 10 additions & 23 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,39 +9,26 @@ on:
- '**.py'

jobs:
Black:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: psf/black@stable
with:
options: "--check --verbose"
src: "./src ./tests"
Ruff:
Linting:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: 3.x
- name: Install ruff
- name: Install Project
run: |
python -m pip install --upgrade pip
python -m pip install ruff
- name: Run ruff
python -m pip install .[lint]
- name: Run Black
if: always()
run: |
ruff src
MyPy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: 3.x
- name: Install Project and MyPy
black --check --verbose src tests
- name: Run Ruff
if: always()
run: |
python -m pip install --upgrade pip
python -m pip install .[lint]
ruff src
- name: Run MyPy
if: always()
run: |
mypy src

0 comments on commit 53f01ab

Please sign in to comment.