Skip to content

fix: caching pip dependencies #78

fix: caching pip dependencies

fix: caching pip dependencies #78

Workflow file for this run

name: Linting
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
jobs:
linting:
name: Linting
strategy:
fail-fast: false
matrix:
include:
- {name: black, command: black . --check}
- {name: flake8, command: flake8 .}
- {name: isort, command: isort . --check}
- {name: pylint, command: 'pylint */**.py --evaluation "0 if fatal else max(0, 10 - error - warning)"'}
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Cache pip dependencies
uses: actions/cache@v4
with:
path: ~/.cache/pip
key: linting-pip-${{ hashFiles('**/pyproject.toml') }}
restore-keys:
- linting-pip-

Check failure on line 32 in .github/workflows/linting.yml

View workflow run for this annotation

GitHub Actions / Linting

Invalid workflow file

The workflow is not valid. .github/workflows/linting.yml (Line: 32, Col: 11): A sequence was not expected
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version-file: pyproject.toml
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -e .[dev]
- name: Run ${{ matrix.name }}
run: python -m ${{ matrix.command }}