Run golangci-lint with reviewdog
https://github.com/marketplace?type=actions&query=reviewdog โ HEALTH ? 91 / Healthy
Run golangci-lint with reviewdog
https://github.com/marketplace?type=actions&query=reviewdog โ// readme
This action runs golangci-lint with reviewdog on pull requests to improve code review experience.
In many cases, you need to do nothing. Just use reviewdog/action-golangci-lint@v2 instead of reviewdog/action-golangci-lint@v1.
If your workflow have steps for setting up Go and caching go modules, they are no longer needed.
reviewdog/action-golangci-lint@v2 now set up Go and cache modules automatically, so remove these steps.
on: [pull_request]
jobs:
golangci-lint:
runs-on: ubuntu-latest
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0
# no need with v2
# - name: Set up Go
# uses: actions/setup-go@v2
# with:
# go-version: '1.17'
# no need with v2
# - uses: actions/cache@v2
# with:
# path: |
# ~/.cache/golangci-lint
# ~/.cache/go-build
# ~/go/pkg/modโฆ