-
Notifications
You must be signed in to change notification settings - Fork 39
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
ci: add GitHub Workflow for golangci-lint #365
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nixpanic
force-pushed
the
workflow/golangci-lint
branch
from
June 12, 2023 07:09
959da6b
to
14528f0
Compare
Based on the example in the golangci-lint GitHub Action documentnation. See-also: https://github.com/golangci/golangci-lint-action Signed-off-by: Niels de Vos <[email protected]>
nixpanic
force-pushed
the
workflow/golangci-lint
branch
from
June 12, 2023 07:11
14528f0
to
2b8096e
Compare
…bHook validation golangci-lint complains that `rscjLog` is not used. This seems to be correct, as the validating WebHook for ReclaimSpaceCronJob used the wrong logger. Signed-off-by: Niels de Vos <[email protected]>
…rDriverNotFound` The `errDriverNotFound` error is not used anymore. Signed-off-by: Niels de Vos <[email protected]>
…in `Deploy()` `Deploy()` always returns `nil`, even when `wait.PollImmediateInfinite()` would return an error. At the moment, no errors are returned while polling, everything seems to be handled. In case this changes in the future, the error will be returned now. Signed-off-by: Niels de Vos <[email protected]>
golangci-lint noticed thet `getSecret()` is not used. There probably is no need for this function in `main.go` anyway, it would probably be cleaner to fetch a Secret in the Controller or Side-Car when it is needed. Signed-off-by: Niels de Vos <[email protected]>
golangci-lint reports that `grpc.WithInsecure()` has been deprecated. It can be replaced by `grps.WithTransportCredentials() and pass credentials created with `insecure.NewCredentials()`. Signed-off-by: Niels de Vos <[email protected]>
Signed-off-by: Niels de Vos <[email protected]>
nixpanic
force-pushed
the
workflow/golangci-lint
branch
from
June 12, 2023 08:12
e060a34
to
f606706
Compare
golangci-lint complains that `cfg` is not used. Other unit-tests use the global `cfg` variable, so use that in the controller test suite too. Signed-off-by: Niels de Vos <[email protected]>
Signed-off-by: Niels de Vos <[email protected]>
Madhu-1
approved these changes
Jun 12, 2023
yati1998
approved these changes
Jun 12, 2023
4 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Based on the example in the golangci-lint GitHub Action documentnation.
Note: this PR is a draft until there are no linter issues reported anymore.