name: CI on: push: pull_request: jobs: check: name: Lint, test and scan runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v4 - name: Set up Go uses: actions/setup-go@v5 with: # Latest patch of the current release, so standard-library security # fixes are picked up without editing this file. go-version: "1.27.x" check-latest: true - name: gofmt run: | unformatted="$(gofmt -l .)" if [ -n "$unformatted" ]; then echo "These files need gofmt:"; echo "$unformatted"; exit 1 fi - name: go vet run: go vet ./... - name: staticcheck run: go tool staticcheck ./... - name: Test (race detector) run: go test -race ./... - name: govulncheck run: go tool govulncheck ./...