-
Notifications
You must be signed in to change notification settings - Fork 13
update go to 1.24 and golangci-lint to 2.1.5 #66
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
Conversation
.golangci.yml
Outdated
presets: | ||
- comments | ||
- common-false-positives | ||
- legacy | ||
- std-error-handling |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ISTR specifying these makes it skip some (not run "more")? Wondering if CY is happy if presents is empty?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah true and it fails for comments
preset:
#20 [lint 1/1] RUN --mount=type=bind,target=. --mount=type=cache,target=/root/.cache --mount=from=golangci-lint,source=/usr/bin/golangci-lint,target=/usr/bin/golangci-lint golangci-lint run ./...
#20 0.995 annotation/annotation.go:15:1: package-comments: should have a package comment (revive)
#20 0.995 package annotation
#20 0.995 ^
#20 0.995 clidocstool.go:15:1: package-comments: should have a package comment (revive)
#20 0.995 package clidocstool
#20 0.995 ^
#20 0.995 2 issues:
#20 0.995 * revive: 2
#20 ERROR: process "/bin/sh -c golangci-lint run ./..." did not complete successfully: exit code: 1
I guess we can just exclude this one as it was not catched before?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, yes, either we can add a package comment (if there's only a few) or we can add excludes for a couple; https://github.com/moby/moby/blob/7937f0846c130e91836f5f640c41ce12d07da4c8/.golangci.yml#L152-L158
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, yes, either we can add a package comment (if there's only a few) or we can add excludes for a couple; https://github.com/moby/moby/blob/7937f0846c130e91836f5f640c41ce12d07da4c8/.golangci.yml#L152-L158
Is this one complementary or a duplicate https://github.com/moby/moby/blob/7937f0846c130e91836f5f640c41ce12d07da4c8/.golangci.yml#L146-L150 of staticcheck - -ST1000
? Here seems only a revive rule.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added comments to packages
Signed-off-by: CrazyMax <[email protected]>
Signed-off-by: CrazyMax <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
No description provided.