brewlog/.github/workflows/push.yml
Jon Seager 6431d97afa
ci: remove push trigger from CI workflow
Only run CI on pull requests to main, not on direct pushes.
2026-02-06 18:58:41 +00:00

31 lines
780 B
YAML

name: CI
on:
pull_request:
branches: ["main"]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
name: Run Tests
runs-on: ubuntu-latest
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Install nix
uses: DeterminateSystems/nix-installer-action@main
- name: Setup Nix cache
uses: nix-community/cache-nix-action@main
with:
primary-key: nix-${{ runner.os }}-${{ hashFiles('**/*.nix', '**/flake.lock') }}
restore-prefixes-first-match: nix-${{ runner.os }}-
- name: Run tests
run: |
nix develop --command cargo test -- --show-output