Skip to content
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

Fix up UI messages #2629

Merged
merged 2 commits into from
Jan 24, 2023
Merged

Fix up UI messages #2629

merged 2 commits into from
Jan 24, 2023

Conversation

znewman01
Copy link
Contributor

Signed-off-by: Zachary Newman zjn@chainguard.dev

Summary

Release Note

Documentation

Signed-off-by: Zachary Newman <zjn@chainguard.dev>
dlorenc
dlorenc previously approved these changes Jan 15, 2023
@@ -155,7 +152,7 @@ func SignCmd(ro *options.RootOptions, ko options.KeyOpts, signOpts options.SignO

var staticPayload []byte
if signOpts.PayloadPath != "" {
ui.Info(ctx, "Using payload from:", signOpts.PayloadPath)
ui.Info(ctx, "Using payload from: %s", signOpts.PayloadPath)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit will be good to have this called InfoF to match similar pattern like PrintF SPrintF ...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Signed-off-by: Zachary Newman <zjn@chainguard.dev>
@znewman01
Copy link
Contributor Author

znewman01 commented Jan 18, 2023

I wanted to add golanglint support via govet but it doesn't work for me :(

(It works when I run go vet -printf.funcs=github.com/sigstore/cosign/v2/internal/ui.Infof,github.com/sigstore/cosign/v2/internal/ui.Warnf ./... but not when I set linters-settings.govet.settings.printf.funcs (golanglint docs).)

@codecov-commenter
Copy link

Codecov Report

Merging #2629 (208ec59) into main (29360f6) will increase coverage by 0.00%.
The diff coverage is 30.55%.

@@           Coverage Diff           @@
##             main    #2629   +/-   ##
=======================================
  Coverage   30.03%   30.04%           
=======================================
  Files         146      146           
  Lines        9283     9280    -3     
=======================================
  Hits         2788     2788           
+ Misses       6065     6062    -3     
  Partials      430      430           
Impacted Files Coverage Δ
cmd/cosign/cli/clean.go 0.00% <0.00%> (ø)
cmd/cosign/cli/fulcio/fulcio.go 16.53% <0.00%> (ø)
cmd/cosign/cli/generate/generate_key_pair.go 29.26% <0.00%> (ø)
cmd/cosign/cli/importkeypair/import_key_pair.go 44.44% <0.00%> (ø)
pkg/cosign/tlog.go 39.19% <0.00%> (ø)
cmd/cosign/cli/sign/sign.go 15.78% <6.66%> (+0.12%) ⬆️
internal/ui/log.go 100.00% <100.00%> (ø)
pkg/policy/eval.go 79.48% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@znewman01 znewman01 merged commit fb74f73 into sigstore:main Jan 24, 2023
@github-actions github-actions bot added this to the v1.14.0 milestone Jan 24, 2023
uralsemih pushed a commit to uralsemih/cosign that referenced this pull request Jan 29, 2023
* Fix up UI messages

Signed-off-by: Zachary Newman <zjn@chainguard.dev>

* Rename Warn/Info to Warnf/Infof

Signed-off-by: Zachary Newman <zjn@chainguard.dev>

Signed-off-by: Zachary Newman <zjn@chainguard.dev>
dmitris pushed a commit to dmitris/cosign that referenced this pull request Mar 24, 2023
* Fix up UI messages

Signed-off-by: Zachary Newman <zjn@chainguard.dev>

* Rename Warn/Info to Warnf/Infof

Signed-off-by: Zachary Newman <zjn@chainguard.dev>

Signed-off-by: Zachary Newman <zjn@chainguard.dev>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants