AGENTS.md: add persistent on-disk cache (diskcache) to 'when you need it' #20
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: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| workflow_dispatch: | |
| concurrency: | |
| group: ci-${{ github.ref }} | |
| cancel-in-progress: true | |
| permissions: | |
| contents: read | |
| jobs: | |
| check: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 30 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| # uv path — runs for everyone | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v3 | |
| with: | |
| enable-cache: true | |
| cache-dependency-glob: "uv.lock" | |
| - name: Set up Python | |
| run: uv python install | |
| - name: Install deps | |
| run: uv sync --frozen | |
| - name: Inner loop (uv) | |
| run: make check | |
| # nix path — only if the user kept flake.nix | |
| - name: Install Nix | |
| if: ${{ hashFiles('flake.nix') != '' }} | |
| uses: cachix/install-nix-action@v30 | |
| with: | |
| extra_nix_config: | | |
| experimental-features = nix-command flakes | |
| - name: Inner loop (nix develop) | |
| if: ${{ hashFiles('flake.nix') != '' }} | |
| run: nix develop -c make check | |
| # Proves the uv2nix wiring resolves end-to-end: project + deps build | |
| # under pure Nix (no uv at build time). Catches lockfile drift and | |
| # missing build-backend overrides early. | |
| - name: Build venv (nix) | |
| if: ${{ hashFiles('flake.nix') != '' }} | |
| run: nix build .#default --print-build-logs | |
| # Runs `checks.${system}.*` from flake.nix: statix + nixfmt --check. | |
| # Also re-evaluates devShells/packages/inputs as a smoke test. | |
| - name: Flake check (statix + nixfmt) | |
| if: ${{ hashFiles('flake.nix') != '' }} | |
| run: nix flake check --print-build-logs |