Skip to content

chore: Enable revive and stylecheck in golangci linters#849

Merged
ctreatma merged 2 commits into
mainfrom
linter_updates
Feb 4, 2025
Merged

chore: Enable revive and stylecheck in golangci linters#849
ctreatma merged 2 commits into
mainfrom
linter_updates

Conversation

@thogarty
Copy link
Copy Markdown
Contributor

  • Enable revive and stylecheck linters

Comment thread .golangci.yaml
Signed-off-by: Charles Treatman <1090793+ctreatma@users.noreply.github.com>
@ctreatma ctreatma merged commit c8d9aa7 into main Feb 4, 2025
@ctreatma ctreatma deleted the linter_updates branch February 4, 2025 19:06
ctreatma added a commit that referenced this pull request Feb 5, 2025
Since we might periodically change linter configuration, as done in
#849, we should keep the existing PR validation behavior that only lints
the files that were changed in a particular PR. This will allow us to
continue to avoid unnecessarily large PRs to fix linting failures if and
when the linter configuration changes.

If we're keeping the current, limited PR validation behavior, we should
use the same behavior for the `make lint` task to that developers can
easily identify the minimum necessary changes locally. This updates the
`make lint` task to only lint files that have been changed since
`origin/main`, which should closely approximate the behavior of the PR
validation workflow.
@github-actions
Copy link
Copy Markdown

This PR is included in version 3.2.0 🎉

kpdhulipala pushed a commit to kpdhulipala/terraform-provider-equinix that referenced this pull request Mar 24, 2025
* Enable `revive` and `stylecheck` linters

---------

Signed-off-by: Charles Treatman <1090793+ctreatma@users.noreply.github.com>
Co-authored-by: Charles Treatman <1090793+ctreatma@users.noreply.github.com>
kpdhulipala pushed a commit to kpdhulipala/terraform-provider-equinix that referenced this pull request Mar 24, 2025
Since we might periodically change linter configuration, as done in
equinix#849, we should keep the existing PR validation behavior that only lints
the files that were changed in a particular PR. This will allow us to
continue to avoid unnecessarily large PRs to fix linting failures if and
when the linter configuration changes.

If we're keeping the current, limited PR validation behavior, we should
use the same behavior for the `make lint` task to that developers can
easily identify the minimum necessary changes locally. This updates the
`make lint` task to only lint files that have been changed since
`origin/main`, which should closely approximate the behavior of the PR
validation workflow.
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

Successfully merging this pull request may close these issues.

2 participants