Generic github event context #124
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: linting | |
on: | |
push: | |
paths: | |
- "**.go" | |
- go.mod | |
- go.sum | |
branches: ["main"] | |
pull_request: | |
paths: | |
- "**.go" | |
- go.mod | |
- go.sum | |
branches: ["main"] | |
permissions: | |
contents: read | |
# Optional: allow read access to pull request. Use with `only-new-issues` option. | |
# pull-requests: read | |
jobs: | |
lint: | |
name: lint | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
go: [ '1.21' ] | |
steps: | |
- name: Set up go | |
uses: actions/setup-go@v4 | |
with: | |
go-version: ${{ matrix.go }} | |
check-latest: true | |
- name: Checkout the source code | |
uses: actions/checkout@v3 | |
- name: Verify the dependencies | |
run: | | |
go mod verify | |
go mod download | |
- name: Lint | |
uses: golangci/golangci-lint-action@v3 | |
with: | |
version: latest | |
args: --timeout 15m0s --verbose --out-${IGNORE_FUTURE_WARNINGS}format tab | |