Update pre-commit hook charliermarsh/ruff-pre-commit to v0.14.3 #189
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [master] | |
| pull_request: ~ | |
| env: | |
| FORCE_COLOR: 1 | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - uses: jdx/mise-action@v3 | |
| - name: Cache pre-commit environment | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.cache/pre-commit | |
| key: pre-commit-${{ runner.os }}-${{ hashFiles('.pre-commit-config.yaml') }} | |
| restore-keys: | | |
| pre-commit-${{ runner.os }}- | |
| - uses: actions/cache@v4 | |
| with: | |
| path: ~/.local/share/virtualenvs | |
| key: ${{ runner.os }}-poetry-${{ hashFiles('poetry.lock') }} | |
| restore-keys: | | |
| ${{ runner.os }}-poetry- | |
| - name: Install pip dependencies | |
| run: poetry install | |
| - name: Run pre-commit | |
| run: pre-commit run --all-files --show-diff-on-failure --color=always | |
| test: | |
| runs-on: ubuntu-24.04 | |
| strategy: | |
| matrix: | |
| python-version: ['3.13', '3.12', '3.11', '3.10'] | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: '${{ matrix.python-version }}' | |
| - name: Get Poetry version from .mise.toml | |
| uses: SebRollen/toml-action@v1.2.0 | |
| id: get-poetry-version | |
| with: | |
| file: .mise.toml | |
| field: tools.poetry | |
| - name: Install poetry | |
| uses: abatilo/actions-poetry@v4.0.0 | |
| with: | |
| poetry-version: ${{ steps.get-poetry-version.outputs.value }} | |
| - uses: actions/cache@v4 | |
| with: | |
| path: ~/.local/share/virtualenvs | |
| key: ${{ runner.os }}-${{ matrix.python-version }}-poetry-${{ hashFiles('poetry.lock') }} | |
| restore-keys: | | |
| ${{ runner.os }}-poetry- | |
| - uses: actions/cache@v4 | |
| with: | |
| path: ~/.local/share/virtualenvs | |
| key: ${{ runner.os }}-poetry-${{ hashFiles('poetry.lock') }} | |
| restore-keys: | | |
| ${{ runner.os }}-poetry- | |
| - name: Install pip dependencies | |
| run: poetry install | |
| - name: Run tests | |
| run: poetry run pytest |