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

Bind flags as prefixed env variables #2346

Merged
merged 3 commits into from
Oct 18, 2022

Conversation

hectorj2f
Copy link
Contributor

@hectorj2f hectorj2f commented Oct 17, 2022

Signed-off-by: Hector Fernandez [email protected]

Summary

There is an increase in the amount of flags used in our commands. Therefore we should think about binding these flags as environment variables that would help us when using the commands.

closes #2330

Release Note

Allow setting flag values via environment variables

Documentation

@hectorj2f hectorj2f self-assigned this Oct 17, 2022
@codecov-commenter
Copy link

Codecov Report

Merging #2346 (88d16d7) into main (ef9cf9d) will decrease coverage by 0.16%.
The diff coverage is 0.00%.

@@            Coverage Diff             @@
##             main    #2346      +/-   ##
==========================================
- Coverage   29.87%   29.70%   -0.17%     
==========================================
  Files         134      134              
  Lines        8289     8335      +46     
==========================================
  Hits         2476     2476              
- Misses       5482     5528      +46     
  Partials      331      331              
Impacted Files Coverage Δ
cmd/cosign/cli/attach.go 0.00% <0.00%> (ø)
cmd/cosign/cli/attest.go 0.00% <0.00%> (ø)
cmd/cosign/cli/attest_blob.go 0.00% <0.00%> (ø)
cmd/cosign/cli/clean.go 0.00% <0.00%> (ø)
cmd/cosign/cli/completion.go 0.00% <0.00%> (ø)
cmd/cosign/cli/copy.go 0.00% <0.00%> (ø)
cmd/cosign/cli/dockerfile.go 0.00% <0.00%> (ø)
cmd/cosign/cli/download.go 0.00% <0.00%> (ø)
cmd/cosign/cli/generate.go 0.00% <0.00%> (ø)
cmd/cosign/cli/generate_key_pair.go 0.00% <0.00%> (ø)
... and 14 more

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

@hectorj2f hectorj2f force-pushed the bind_flags_as_env_vars branch 2 times, most recently from 81366a8 to 3f94ed3 Compare October 17, 2022 14:39
Copy link
Contributor

@priyawadhwa priyawadhwa left a comment

Choose a reason for hiding this comment

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

This looks great @hectorj2f !!

cmd/cosign/cli/options/root.go Show resolved Hide resolved
Signed-off-by: Hector Fernandez <[email protected]>
@hectorj2f hectorj2f marked this pull request as ready for review October 18, 2022 09:12
@hectorj2f hectorj2f added the enhancement New feature or request label Oct 18, 2022
Copy link
Member

@cpanato cpanato left a comment

Choose a reason for hiding this comment

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

looks cool

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

allow setting flag values via environment variables
5 participants