1
0

golangci-lint.yml 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. name: golangci-lint
  2. on:
  3. push:
  4. branches:
  5. - master
  6. - dev
  7. pull_request:
  8. permissions:
  9. contents: read
  10. # Optional: allow read access to pull request. Use with `only-new-issues` option.
  11. pull-requests: read
  12. jobs:
  13. golangci:
  14. name: lint
  15. runs-on: ubuntu-latest
  16. steps:
  17. - uses: actions/setup-go@v4
  18. with:
  19. go-version: '1.21'
  20. - uses: actions/checkout@v3
  21. - name: golangci-lint
  22. uses: golangci/golangci-lint-action@v3
  23. with:
  24. # Optional: version of golangci-lint to use in form of v1.2 or v1.2.3 or `latest` to use the latest version
  25. version: v1.55
  26. # Optional: golangci-lint command line arguments.
  27. # args: --issues-exit-code=0
  28. # Optional: show only new issues if it's a pull request. The default value is `false`.
  29. # only-new-issues: true
  30. # Optional: if set to true then the all caching functionality will be complete disabled,
  31. # takes precedence over all other caching options.
  32. # skip-cache: true
  33. # Optional: if set to true then the action don't cache or restore ~/go/pkg.
  34. # skip-pkg-cache: true
  35. # Optional: if set to true then the action don't cache or restore ~/.cache/go-build.
  36. # skip-build-cache: true