Adopt shared golangci-lint config from sdk-go [main] - #86
Conversation
Add a `make lint` target that uses the shared lint scripts from sdk-go, and resolve all lint errors including import formatting, naming conventions, deprecated API usage, and unused code. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: xuezhaojun <zxue@redhat.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: xuezhaojun The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #86 +/- ##
==========================================
- Coverage 69.13% 68.94% -0.19%
==========================================
Files 4 4
Lines 891 892 +1
==========================================
- Hits 616 615 -1
- Misses 242 243 +1
- Partials 33 34 +1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
0028cac
into
open-cluster-management-io:main
Summary
make linttarget that uses the shared lint scripts from sdk-go, enabling zero-configuration linting that auto-detects Go version and downloads the appropriate golangci-lint v2open-cluster-management.iolocal-prefix convention acrossclusterpermission_controller.go,clusterpermission_status_controller.go,main.go, andhelper.goVALIDATION_MW_RETRY_INTERVALwas unused, so removed entirely); fixed indent-error-flow ingetSubjects()r.Client.Create/Update/Listtor.Create/Update/Listby removing redundant embedded field selectorhelper.goworkqueue.RateLimitingInterfaceandworkqueue.DefaultControllerRateLimiter()with typed equivalentsaddKnownTypes()function fromgroupversion_info.goTest plan
make lintpasses with 0 issuesgo build ./...compiles successfully🤖 Generated with Claude Code