Skip to content

doc: add examples in CLI help doc for notation sign and verify #384

Merged
shizhMSFT merged 15 commits intonotaryproject:mainfrom
FeynmanZhou:main
Oct 14, 2022
Merged

doc: add examples in CLI help doc for notation sign and verify #384
shizhMSFT merged 15 commits intonotaryproject:mainfrom
FeynmanZhou:main

Conversation

@FeynmanZhou
Copy link
Copy Markdown
Member

fix #383

FeynmanZhou and others added 10 commits June 1, 2022 18:56
Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
Copy link
Copy Markdown
Contributor

@yizha1 yizha1 left a comment

Choose a reason for hiding this comment

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

LGTM

Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
@FeynmanZhou FeynmanZhou added this to the alpha-4 milestone Oct 13, 2022
@FeynmanZhou FeynmanZhou added documentation Improvements or additions to documentation UX User experience changes labels Oct 13, 2022
Copy link
Copy Markdown
Contributor

@priteshbandi priteshbandi left a comment

Choose a reason for hiding this comment

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

LGTM, we will update this command again in RC1

Comment on lines +38 to +39
Long: `
Prerequiste: a signing key needs to be configured using the command "notation key".
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Could you add a title for the help command? Otherwise, it will show

$ ./notation sign --help

Prerequiste: a signing key needs to be configured using the command "notation key".

Example - Sign a container image using the default signing key, with the default JWS envelope:
  notation sign <registry>/<repository>:<tag>

...

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

@shizhMSFT Good catch. Fixed.

Just be aware of the value in the Short field will be omitted when defines a Long field.

The current CLI help UX for notation sign:

 ./notation sign --help

Sign OCI artifacts

Prerequisite: a signing key needs to be configured using the command "notation key".

Example - Sign a container image using the default signing key, with the default JWS envelope:
  notation sign <registry>/<repository>:<tag>

Example - Sign a container image using the default signing key, with the COSE envelope:
  notation sign --envelope-type cose <registry>/<repository>:<tag>

Example - Sign a container image using the specified key name
  notation sign --key <key_name> <registry>/<repository>:<tag>

Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
@FeynmanZhou FeynmanZhou requested a review from shizhMSFT October 14, 2022 03:00
Signed-off-by: Feynman Zhou <feynmanzhou@microsoft.com>
@codecov-commenter
Copy link
Copy Markdown

Codecov Report

Merging #384 (8c3790f) into main (623fd6d) will increase coverage by 1.32%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main     #384      +/-   ##
==========================================
+ Coverage   30.70%   32.03%   +1.32%     
==========================================
  Files          26       26              
  Lines        1638     1670      +32     
==========================================
+ Hits          503      535      +32     
  Misses       1122     1122              
  Partials       13       13              
Impacted Files Coverage Δ
cmd/notation/common.go 100.00% <ø> (ø)
cmd/notation/sign.go 42.45% <100.00%> (+12.56%) ⬆️
cmd/notation/verify.go 26.89% <100.00%> (+8.96%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Copy link
Copy Markdown
Contributor

@shizhMSFT shizhMSFT left a comment

Choose a reason for hiding this comment

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

LGTM

@shizhMSFT shizhMSFT merged commit b9f1fb5 into notaryproject:main Oct 14, 2022
7h3-3mp7y-m4n pushed a commit to 7h3-3mp7y-m4n/notation that referenced this pull request Mar 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation UX User experience changes

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Add examples for notation command help doc

7 participants