File tree Expand file tree Collapse file tree 4 files changed +64
-0
lines changed
Expand file tree Collapse file tree 4 files changed +64
-0
lines changed Original file line number Diff line number Diff line change 1+ name : check
2+
3+ on :
4+ workflow_call :
5+
6+ jobs :
7+ check :
8+ runs-on : ubuntu-24.04
9+ timeout-minutes : 15
10+ concurrency :
11+ group : ${{ github.workflow }}-${{ github.ref }}
12+ cancel-in-progress : true
13+ steps :
14+ - uses : actions/checkout@v4.2.2
15+ with :
16+ fetch-depth : 0
17+
18+ - name : Install Nix
19+ uses : cachix/install-nix-action@v27
20+
21+ - name : Run the Magic Nix Cache
22+ uses : DeterminateSystems/magic-nix-cache-action@v7
23+
24+ - name : Setup flake environment
25+ run : nix develop -c sleep 0
26+ shell : bash
27+
28+ - name : Check Go format
29+ run : nix develop -c ./scripts/check-fmt.sh
30+
31+ - name : Vet
32+ run : nix develop -c go vet ./...
33+
34+ - name : Test
35+ run : nix develop -c go test ./...
36+
37+ - name : Build
38+ run : nix build
Original file line number Diff line number Diff line change 1+ name : Master
2+ on :
3+ push :
4+ branches :
5+ - master
6+
7+ jobs :
8+ check :
9+ uses : ./.github/workflows/_check.yml
Original file line number Diff line number Diff line change 1+ name : Pull requests
2+
3+ on :
4+ pull_request :
5+
6+ jobs :
7+ check :
8+ uses : ./.github/workflows/_check.yml
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ UNFORMATTED_FILES=$( gofmt -l .)
4+
5+ if [ -n " $UNFORMATTED_FILES " ]; then
6+ echo " The following files are not formatted:"
7+ echo " $UNFORMATTED_FILES "
8+ exit 1
9+ fi
You can’t perform that action at this time.
0 commit comments