Commit 44cb7ee485
Unsigned
Layout: unified · split
.github/workflows/build.yml +22
| @@ -9,12 +9,34 @@ permissions: | |||
| 9 | contents: read | 9 | contents: read |
| 10 | 10 | ||
| 11 | env: | 11 | env: |
| 12 | # Pinned so a new ruff release adds rules on your schedule, not mid-PR. | ||
| 13 | RUFF_VERSION: "0.16.4" | ||
| 12 | # orgo is installed from crates.io, so nothing bumps this automatically — | 14 | # orgo is installed from crates.io, so nothing bumps this automatically — |
| 13 | # dependabot does not see `cargo install` in a workflow. Raise it by hand when | 15 | # dependabot does not see `cargo install` in a workflow. Raise it by hand when |
| 14 | # a new orgo lands, which is also how you find out orgo broke the site. | 16 | # a new orgo lands, which is also how you find out orgo broke the site. |
| 15 | ORGO_VERSION: "0.22.0" | 17 | ORGO_VERSION: "0.22.0" |
| 16 | 18 | ||
| 17 | jobs: | 19 | jobs: |
| 20 | # Separate from the build so a lint failure and a broken page are distinct | ||
| 21 | # signals. build.py runs `ruff check --fix` and `ruff format` on development | ||
| 22 | # builds; these are the verifying forms of the same two commands, reading | ||
| 23 | # the same ruff.toml, so CI cannot disagree with a local dev build. | ||
| 24 | lint: | ||
| 25 | runs-on: ubuntu-latest | ||
| 26 | steps: | ||
| 27 | - uses: actions/checkout@v7 | ||
| 28 | |||
| 29 | - name: Install ruff | ||
| 30 | run: pipx install "ruff==$RUFF_VERSION" | ||
| 31 | |||
| 32 | - name: Lint | ||
| 33 | run: | | ||
| 34 | ruff --version | ||
| 35 | ruff check --no-fix | ||
| 36 | |||
| 37 | - name: Format | ||
| 38 | run: ruff format --check --diff | ||
| 39 | |||
| 18 | build: | 40 | build: |
| 19 | runs-on: ubuntu-latest | 41 | runs-on: ubuntu-latest |
| 20 | steps: | 42 | steps: |