Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Module Plugin System support #713

Open
yizeng opened this issue Jul 9, 2024 · 0 comments
Open

Module Plugin System support #713

yizeng opened this issue Jul 9, 2024 · 0 comments

Comments

@yizeng
Copy link

yizeng commented Jul 9, 2024

Just wanted to check how to use this action with golangci-lint's Module Plugin System?

More context:

I have a project that is currently using reviewdog/action-golangci-lint@v2 to run golangci-lint. Everything is fine.

  go-lint:
    name: "Lint Go"
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v4
    - name: versions
      id: versions
      run: |
        cat go.mod | grep "^go" | awk '{print "go="$2}' >> $GITHUB_OUTPUT
        cat go.mod | grep golangci-lint | awk '{print "golangci-lint="$2}' >> $GITHUB_OUTPUT
    - name: golangci-lint
      uses: reviewdog/action-golangci-lint@v2
      with:
        go_version: ${{ steps.versions.outputs.go }}
        golangci_lint_version: ${{ steps.versions.outputs.golangci-lint }}
        reporter: github-pr-review
        filter_mode: nofilter
        golangci_lint_flags: '--config=.golangci.yml --timeout=9m --new-from-rev=HEAD~1'
        fail_on_error: true

Now I'm integrating uber-go/nilaway into our golangci-lint as per documentation here.

So locally, instead of simply use golangci-lint run ./..., I will need to use a custom gcl like this:

  • golangci-lint custom
  • ./custom-gcl run ./...

How can I utilize reviewdog/action-golangci-lint to run custom-gcl on GitHub Actions?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant