chore(deps): bump arnested/go-version-action from 1.1.21 to 1.1.22 #669
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: go | |
| on: | |
| pull_request: | |
| permissions: | |
| contents: read | |
| pull-requests: write | |
| security-events: write | |
| actions: read | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Harden the runner (Audit all outbound calls) | |
| uses: step-security/harden-runner@f4a75cfd619ee5ce8d5b864b0d183aff3c69b55a # v2.13.1 | |
| with: | |
| egress-policy: audit | |
| - name: Checkout code | |
| uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 | |
| - name: Extract Go version | |
| uses: arnested/go-version-action@1f4135a30a2498f919e428c81c342f9334b3a93d # v1.1.22 | |
| id: go-version | |
| - name: Split version code | |
| uses: step-security/split-strings@d2212424ae73f4709b3a56faaf96ea42d189102f # v1.0.1 | |
| id: split | |
| with: | |
| string: ${{ steps.go-version.outputs.go-mod-version }} | |
| separator: . | |
| limit: 2 | |
| - name: Set up Go | |
| uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0 | |
| with: | |
| go-version: '${{ steps.split.outputs._0 }}.${{ steps.split.outputs._1 }}' | |
| check-latest: true | |
| cache: true | |
| - name: Install dependencies | |
| run: go mod download | |
| - name: Verify dependencies | |
| run: go mod verify | |
| - name: Build | |
| run: go build -v ./... | |
| - name: Go Format | |
| run: gofmt -s -w . && git diff --exit-code | |
| - name: Go Generate | |
| run: go generate ./... && git diff --exit-code | |
| - id: govulncheck | |
| uses: golang/govulncheck-action@b625fbe08f3bccbe446d94fbf87fcc875a4f50ee # v1.0.4 | |
| with: | |
| go-version-input: '${{ steps.split.outputs._0 }}.${{ steps.split.outputs._1 }}' | |
| go-package: ./... | |
| output-format: sarif | |
| output-file: results.sarif | |
| - name: Upload SARIF file | |
| uses: github/codeql-action/upload-sarif@192325c86100d080feab897ff886c34abd4c83a3 # v3.29.5 | |
| with: | |
| sarif_file: results.sarif | |
| category: govulncheck | |
| - name: Vet | |
| run: go vet ./... | |
| - name: Test | |
| run: go test ./... -v |