diff options
author | 2024-12-16 11:58:27 +0100 | |
---|---|---|
committer | 2024-12-16 11:58:27 +0100 | |
commit | 158243422685160da9190d8b55c2a11254ab4006 (patch) | |
tree | 1a5ebb0818d4b72ad8770e5bbd872d3323a75275 /cmd | |
parent | 8d3ab2d0e82ecd79c0180b10b5aede98fab9a65f (diff) |
release_config_lib: teach redacted print to respect --quiet
When running `build-flag --quiet`, the tool still prints information
about redacted flags. Change the print calling printf to calling warnf,
which will skip printing to stdout in case --quiet was used.
Bug: 384438973
Test: build-flag --quiet get --all | head # no "Redacting flag" lines
Change-Id: I101309fa26994522de16082a67cb5acca76c78d7
Diffstat (limited to 'cmd')
-rw-r--r-- | cmd/release_config/release_config_lib/flag_artifact.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd/release_config/release_config_lib/flag_artifact.go b/cmd/release_config/release_config_lib/flag_artifact.go index cb13fdce4..f493e1e06 100644 --- a/cmd/release_config/release_config_lib/flag_artifact.go +++ b/cmd/release_config/release_config_lib/flag_artifact.go @@ -189,7 +189,7 @@ func (fa *FlagArtifact) UpdateValue(flagValue FlagValue) error { if redacted { fa.Redact() flagValue.proto.Value = fa.Value - fmt.Printf("Redacting flag %s in %s\n", name, flagValue.path) + warnf("Redacting flag %s in %s\n", name, flagValue.path) } else { // If we are assigning a value, then the flag is no longer redacted. fa.Redacted = false |