Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat: upgrade golangci-lint to v2#386

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
williammartin merged 4 commits intogithub:mainfromradar07:upgrade-golangci-lint
May 12, 2025

Conversation

radar07
Copy link
Contributor

Use the latest version ofgolangci-lint and fix the CI workflow.

Closes:#378

Use the latest version of `golangci-lint` and fix the CI workflow.
@radar07radar07 requested a review froma team as acode ownerMay 9, 2025 03:50
@radar07radar07 changed the titlejfeat: upgrade golangci-lint to v2feat: upgrade golangci-lint to v2May 9, 2025
@@ -8,21 +11,25 @@ linters:
- govet
- errcheck
- staticcheck
- gofmt
Copy link
Collaborator

Choose a reason for hiding this comment

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

@radar07 can you talk me through these removals? Are they somewhere else? Were they removed? Are they in core?

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

williammartin reacted with thumbs up emoji
@@ -45,6 +45,6 @@ jobs:
assert-nothing-changed go fmt ./...
assert-nothing-changed go mod tidy

bin/golangci-lint run --out-format=colored-line-number --timeout=3m || STATUS=$?
Copy link
Collaborator

Choose a reason for hiding this comment

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

What's the replacement, if any, for--out-format=colored-line-number?

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

colored-line-number has been enabled by default.

I suppose the--out-format has been removed.

williammartin reacted with thumbs up emoji

formatters:
enable:
- gofmt
Copy link
Collaborator

Choose a reason for hiding this comment

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

@radar07 I removedgci andgolines. I like them but they aren't included in most people's workflows and the errors can be opaque for example:

internal/ghmcp/server.go:17:1: File is not properly formatted (gci)^

Totally unclear how to fix unless you understand whatgci is. Not worth the hassle.

radar07 reacted with thumbs up emoji
- '-QF1008' # Allow embedded structs to be referenced by field
- '-ST1000' # Do not require package comments
revive:
rules:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Turned off a few code comment rules. Not that they are wrong, but because we should turn them on intentionally rather than just because we're doing an upgrade.

radar07 reacted with thumbs up emoji
@williammartin
Copy link
Collaborator

Bypassing last pusher review requirement because my changes were minor to bring the linters into alignment with existingtrunk (excluding some linters) and to fix a few small linter failures.

@williammartinwilliammartin merged commit205b619 intogithub:mainMay 12, 2025
9 checks passed
@radar07radar07 deleted the upgrade-golangci-lint branchMay 15, 2025 12:52
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@williammartinwilliammartinwilliammartin approved these changes

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

golangci-lint run config for outputs
2 participants
@radar07@williammartin

[8]ページ先頭

©2009-2025 Movatter.jp