code cleanup to force linter to work well #3
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: Tests | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| # build with different go versions | |
| build: | |
| name: "Build & Test (Go ${{ matrix.go }})" | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| go: ["1.23"] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - uses: actions/setup-go@v3 | |
| with: | |
| go-version: ${{ matrix.go }} | |
| - name: Build | |
| run: go build | |
| - name: Run tests | |
| run: go test ./... | |
| # Run golangci-lint | |
| lint: | |
| timeout-minutes: 5 | |
| name: Linting | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - name: Install Go | |
| uses: actions/setup-go@v3 | |
| with: | |
| go-version: 1.23 | |
| - name: golangci-lint | |
| uses: golangci/golangci-lint-action@v3 |