Phase 1: the run seam and the Claude Code reference runner (ADR-0008) #61
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: | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: ci-${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| env: | |
| GO_VERSION: "1.26" | |
| GOLANGCI_LINT_VERSION: "v2.12.2" | |
| jobs: | |
| build-test: | |
| name: build & test | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - uses: actions/setup-go@v7 | |
| with: | |
| go-version: ${{ env.GO_VERSION }} | |
| check-latest: true | |
| - name: build | |
| run: go build ./... | |
| - name: vet | |
| run: go vet ./... | |
| - name: gofmt | |
| run: | | |
| unformatted=$(gofmt -s -l .) | |
| if [ -n "$unformatted" ]; then | |
| echo "These files are not gofmt -s clean:" | |
| echo "$unformatted" | |
| exit 1 | |
| fi | |
| - name: test (race) and coverage gate | |
| run: ./scripts/coverage.sh 80 | |
| # The coverage gate above is the one that blocks a merge; Codecov is a | |
| # reporting surface on top of it, so an upload failure must not fail CI. | |
| - name: upload coverage to Codecov | |
| uses: codecov/codecov-action@v7 | |
| with: | |
| files: ./coverage.out | |
| token: ${{ secrets.CODECOV_TOKEN }} | |
| fail_ci_if_error: false | |
| lint: | |
| name: golangci-lint | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - uses: actions/setup-go@v7 | |
| with: | |
| go-version: ${{ env.GO_VERSION }} | |
| - name: install golangci-lint | |
| run: | | |
| curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/HEAD/install.sh \ | |
| | sh -s -- -b "$(go env GOPATH)/bin" "${GOLANGCI_LINT_VERSION}" | |
| - name: golangci-lint | |
| run: "$(go env GOPATH)/bin/golangci-lint run --timeout=5m" | |
| vuln: | |
| name: govulncheck | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - uses: actions/setup-go@v7 | |
| with: | |
| go-version: ${{ env.GO_VERSION }} | |
| - name: govulncheck | |
| run: | | |
| go install golang.org/x/vuln/cmd/govulncheck@latest | |
| "$(go env GOPATH)/bin/govulncheck" ./... |