EPIC: camelCase --> snake_case
#71
Workflow file for this run
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: π Code Quality (Ruff) | |
| on: | |
| push: | |
| branches: [main] | |
| paths: | |
| - "**.py" | |
| - "app/pyproject.toml" | |
| - ".github/workflows/ruff.yml" | |
| pull_request: | |
| branches: [main] | |
| paths: | |
| - "**.py" | |
| - "app/pyproject.toml" | |
| - ".github/workflows/ruff.yml" | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| ruff-check: | |
| name: π Lint & Format Check | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 10 | |
| strategy: | |
| matrix: | |
| python-version: ["3.13"] | |
| steps: | |
| - name: π₯ Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: π Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: πΎ Cache pip dependencies | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.cache/pip | |
| key: ${{ runner.os }}-pip-${{ matrix.python-version }}-${{ hashFiles('**/requirements*.txt', '**/pyproject.toml') }} | |
| restore-keys: | | |
| ${{ runner.os }}-pip-${{ matrix.python-version }}- | |
| ${{ runner.os }}-pip- | |
| - name: π¦ Install Ruff | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install ruff | |
| - name: β¨ Check code formatting | |
| run: | | |
| ruff format --check --diff . | |
| - name: π Lint code | |
| run: | | |
| ruff check --output-format=github . | |
| - name: π Generate Ruff report | |
| if: failure() | |
| run: | | |
| echo "## π Ruff Issues Found" >> $GITHUB_STEP_SUMMARY | |
| echo "The following issues were found by Ruff:" >> $GITHUB_STEP_SUMMARY | |
| echo '```' >> $GITHUB_STEP_SUMMARY | |
| ruff check --output-format=text . >> $GITHUB_STEP_SUMMARY || true | |
| echo '```' >> $GITHUB_STEP_SUMMARY |