Skip to content

chore(ci): linting job changes regarding goheader #116

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

Merged
merged 1 commit into from
Feb 5, 2025

Conversation

qdm12
Copy link

@qdm12 qdm12 commented Feb 4, 2025

Why this should be merged

goheader only needs to be run on files changed in the current PR as it will otherwise suggest updating copyright years on untouched files. The other linters, however, should be run in the same manner as a local invocation.

(this was thought about in #115)

How this works

  • golangci-lint runs in its own job step as configured in .golangci.yml (same as locally)
  • goheader runs in its own job step on new issues only

How this was tested

Linting CI passing

- golangci-lint runs as configured in .golangci.yml
- goheader runs separately on new issues only
@qdm12 qdm12 mentioned this pull request Feb 4, 2025
3 tasks
@qdm12 qdm12 marked this pull request as ready for review February 4, 2025 15:08
@qdm12 qdm12 changed the title chore(ci): linting job steps changes chore(ci): linting job changes regarding goheader Feb 4, 2025
@ARR4N
Copy link
Collaborator

ARR4N commented Feb 4, 2025

Why is this necessary? What is it about --enable that's insufficient?

@qdm12
Copy link
Author

qdm12 commented Feb 4, 2025

So this only enables goheader in that CI step, so that it runs on new changes.
The rest (as locally) runs in another CI step, on everything (matching the "libevm" file path), not just new changes

--enable enables on top of existing linters, whereas --enable-only enables just that goheader linter and disables all other linters

Copy link
Collaborator

@ARR4N ARR4N left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the clarification. I've modified the PR description because I don't think it captured the rationale.

@qdm12 qdm12 merged commit be6e93e into main Feb 5, 2025
5 checks passed
@qdm12 qdm12 deleted the qdm12/ci/lint-goheader-split branch February 5, 2025 08:10
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