Skip to content

Chore/qa 1202 sonarqube integration #1195

Chore/qa 1202 sonarqube integration

Chore/qa 1202 sonarqube integration #1195

Workflow file for this run

name: golangci_lint
on:
pull_request:
jobs:
golang_lint:
name: Golang Lint
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3.3.0
- uses: smartcontractkit/[email protected]
id: tool-versions
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version-file: "go.mod"
check-latest: true
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
# Optional: version of golangci-lint to use in form of v1.2 or v1.2.3 or `latest` to use the latest version
version: v${{ steps.tool-versions.outputs.golangci-lint_version }}
# Optional: working directory, useful for monorepos
# working-directory: somedir
# Optional: golangci-lint command line arguments.
args: --enable=gofmt --tests=false --exclude-use-default --timeout=5m0s
# Optional: show only new issues if it's a pull request. The default value is `false`.
only-new-issues: true
# Optional: if set to true then the action don't cache or restore ~/go/pkg.
# skip-pkg-cache: true
# Optional: if set to true then the action don't cache or restore ~/.cache/go-build.
# skip-build-cache: true
- name: Store lint report artifact
if: always()
uses: actions/upload-artifact@3cea5372237819ed00197afe530f5a7ea3e805c8 # v3.1.0
with:
name: golangci-lint-report
path: golangci-lint-report.xml