Skip to content

⬆️ Update dependency ruff to v0.9.4 #61

⬆️ Update dependency ruff to v0.9.4

⬆️ Update dependency ruff to v0.9.4 #61

Workflow file for this run

---
name: Linting
# yamllint disable-line rule:truthy
on:
push:
pull_request:
workflow_dispatch:
env:
DEFAULT_PYTHON: "3.11"
jobs:
ruff:
name: Ruff
runs-on: ubuntu-latest
steps:
- name: ‡️ Check out code from GitHub
uses: actions/[email protected]
- name: πŸ— Set up Poetry
run: pipx install poetry
- name: πŸ— Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/[email protected]
with:
python-version: ${{ env.DEFAULT_PYTHON }}
cache: "poetry"
- name: πŸ— Install workflow dependencies
run: |
poetry config virtualenvs.create true
poetry config virtualenvs.in-project true
- name: πŸ— Install Python dependencies
run: poetry install --no-interaction
- name: πŸš€ Run ruff linter
run: poetry run ruff check --output-format=github .
- name: πŸš€ Run ruff formatter
run: poetry run ruff format --check .
pre-commit-hooks:
name: pre-commit-hooks
runs-on: ubuntu-latest
steps:
- name: ‡️ Check out code from GitHub
uses: actions/[email protected]
- name: πŸ— Set up Poetry
run: pipx install poetry
- name: πŸ— Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/[email protected]
with:
python-version: ${{ env.DEFAULT_PYTHON }}
cache: "poetry"
- name: πŸ— Install workflow dependencies
run: |
poetry config virtualenvs.create true
poetry config virtualenvs.in-project true
- name: πŸ— Install Python dependencies
run: poetry install --no-interaction
- name: πŸš€ Check Python AST
run: poetry run pre-commit run check-ast --all-files
- name: πŸš€ Check for case conflicts
run: poetry run pre-commit run check-case-conflict --all-files
- name: πŸš€ Check docstring is first
run: poetry run pre-commit run check-docstring-first --all-files
- name: πŸš€ Check JSON files
run: poetry run pre-commit run check-json --all-files
- name: πŸš€ Check YAML files
run: poetry run pre-commit run check-yaml --all-files
- name: πŸš€ Detect Private Keys
run: poetry run pre-commit run detect-private-key --all-files
- name: πŸš€ Check End of Files
run: poetry run pre-commit run end-of-file-fixer --all-files
- name: πŸš€ Trim Trailing Whitespace
run: poetry run pre-commit run trailing-whitespace --all-files