chore: migrate to golangci-lint/v2
#1431
Merged
+384
−340
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What this PR does / why we need it
I was checking originally on the linter issues in https://github.com/open-component-model/ocm-k8s-toolkit and realizing, that there is a newer version of
golangci-lint
available.This PR upgrades to golangci-lint v2.1.5.
I've followed the https://golangci-lint.run/product/migration-guide/ and then added some more exclusions:
ocm/.github/config/golangci.yaml
Lines 141 to 172 in d50bee9
until no more errors occurred.
Not sure if someone wants to fix some of those
staticcheck
.