Merge branch 'main' into pr3 #42
Workflow file for this run
This file contains 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: Client Generator | |
on: [push, pull_request] | |
permissions: | |
contents: read | |
jobs: | |
build: | |
runs-on: ubuntu-24.04 | |
strategy: | |
matrix: | |
go-version: [ '1.23' ] | |
defaults: | |
run: | |
working-directory: generator | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Go ${{ matrix.go-version }} | |
uses: actions/setup-go@v5 | |
with: | |
go-version: ${{ matrix.go-version }} | |
cache-dependency-path: | | |
generator/go.sum | |
- name: Display Go version | |
run: go version | |
- run: go mod tidy | |
- run: go test ./... | |
lint: | |
runs-on: ubuntu-24.04 | |
strategy: | |
matrix: | |
go-version: [ '1.23' ] | |
defaults: | |
run: | |
working-directory: generator | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Go ${{ matrix.go-version }} | |
uses: actions/setup-go@v5 | |
with: | |
go-version: ${{ matrix.go-version }} | |
cache-dependency-path: | | |
generator/go.sum | |
- name: Display Go version | |
run: go version | |
- run: go mod tidy | |
- run: go fmt ./... | |
- run: go vet ./... | |
- run: | | |
# unparam does not seem to have releases. Using `latest` sounds risky. | |
go install mvdan.cc/unparam@57a3b4290ba3724102fdbbe72314f2b782d4bef5 | |
unparam ./... | |
- name: Run `staticcheck` | |
uses: dominikh/[email protected] | |
with: | |
install-go: false | |
cache-key: ${{ matrix.go-version }} | |
working-directory: generator | |
- name: Detect Changes | |
run: git diff --exit-code | |
vuln: | |
runs-on: ubuntu-24.04 | |
strategy: | |
matrix: | |
go-version: [ '1.23' ] | |
defaults: | |
run: | |
working-directory: generator | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Go ${{ matrix.go-version }} | |
uses: actions/setup-go@v5 | |
with: | |
go-version: ${{ matrix.go-version }} | |
cache-dependency-path: | | |
generator/go.sum | |
- name: Display Go version | |
run: go version | |
- run: | | |
go install golang.org/x/vuln/cmd/[email protected] | |
govulncheck ./... |