✨ feat: add verbose logging option to controller-gen#1273
✨ feat: add verbose logging option to controller-gen#1273wazery wants to merge 1 commit intokubernetes-sigs:mainfrom
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: wazery 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 |
|
Hi @wazery. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
af08133 to
f076494
Compare
|
@JoelSpeed many thanks for the valuable insights, I reflected them all in the PR now. |
f076494 to
960e43d
Compare
| if logLevel == 0 { | ||
| logLevel = slog.LevelInfo | ||
| } |
There was a problem hiding this comment.
Aren't 0 and slog.LevelInfo equivalent?
| // Set up logging based on log level setting | ||
| var logger *slog.Logger |
There was a problem hiding this comment.
Why not declare this inline with :=?
|
PR needs rebase. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
Adds verbose logging to controller-gen which is disabled by default, and can be enabled. It uses
slogas suggested in the issue #889Example:
./controller-gen crd verbose=true paths=./pkg/crd/testdata output:stdoutFixes: #889