Clean up unneeded flake-check duplication

The cachix action already only pushes from protected branches, based on
the presence of the auth token.
This commit is contained in:
Bryan Richter 2026-04-13 09:37:16 +03:00
parent e9456a0e30
commit 536f0311cf
No known key found for this signature in database
GPG Key ID: B202264020068BFB

View File

@ -1,4 +1,5 @@
name: check and push
# CI that runs on pull requests and pushes to master.
name: CI
on:
push:
branches:
@ -11,29 +12,14 @@ jobs:
stack-test:
uses: ./.github/workflows/stack-test.yml
flake-no-push:
name: flake check (no push)
if: github.event_name != 'push'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v31
- uses: cachix/cachix-action@v15
with:
name: stackage-infrastructure
- run: nix build
- run: nix flake check
flake-push:
flake-check:
name: flake check and push
if: github.event_name == 'push'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
- uses: cachix/install-nix-action@v31
- uses: cachix/cachix-action@v15
with:
name: stackage-infrastructure
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
- uses: DeterminateSystems/magic-nix-cache-action@v13
- uses: cachix/cachix-action@v17
- run: nix build
- run: nix flake check