ALPHA: wire is a tool to deploy nixos systems wire.althaea.zone/
at stable 66 lines 2.1 kB view raw
1--- 2name: autofix.ci 3on: 4 pull_request: 5 push: 6 7permissions: 8 contents: read 9 10jobs: 11 check-changes: 12 runs-on: ubuntu-latest 13 outputs: 14 docs-pnpm: ${{ steps.filter.outputs.docs-pnpm }} 15 steps: 16 - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 17 with: 18 persist-credentials: false 19 - uses: dorny/paths-filter@668c092af3649c4b664c54e4b704aa46782f6f7c 20 id: filter 21 with: 22 filters: | 23 docs-pnpm: 24 - 'doc/pnpm-lock.yaml' 25 autofix: 26 runs-on: blacksmith-2vcpu-ubuntu-2404 27 needs: check-changes 28 env: 29 UV_CACHE_DIR: /tmp/.uv-cache 30 steps: 31 - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 32 with: 33 persist-credentials: false 34 - uses: ./.github/actions/setup-nix 35 - name: Cache Cargo 36 uses: actions/cache@v5 37 with: 38 path: | 39 ~/.cargo/bin/ 40 ~/.cargo/registry/index/ 41 ~/.cargo/registry/cache/ 42 ~/.cargo/git/db/ 43 key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} 44 - name: Cache uv 45 uses: actions/cache@v5 46 with: 47 path: /tmp/.uv-cache 48 key: uv-${{ runner.os }}-${{ hashFiles('**/uv.lock') }} 49 restore-keys: | 50 uv-${{ runner.os }}-${{ hashFiles('**/uv.lock') }} 51 uv-${{ runner.os }} 52 - name: setup sqlx 53 run: nix develop -L -v -c sqlx database setup --source ./crates/core/src/cache/migrations/ 54 - name: autofix sqlx 55 run: nix develop -L -v -c cargo sqlx prepare --workspace 56 - name: clippy --fix 57 run: nix develop -L -v -c cargo clippy --fix 58 - name: pre-commit run 59 run: nix develop -L -v -c pre-commit run --all-files 60 continue-on-error: true 61 - name: Upgrade Hash 62 if: ${{ needs.check-changes.outputs.docs-pnpm == 'true' }} 63 run: bash ./doc/upgrade.sh 64 - name: Minimise uv cache 65 run: nix develop -L -v -c uv cache prune --ci 66 - uses: autofix-ci/action@635ffb0c9798bd160680f18fd73371e355b85f27