From a48deb95371666d1e7eba8a3781ecd5434156fa8 Mon Sep 17 00:00:00 2001 From: Scott Moser Date: Tue, 11 Jun 2024 07:48:46 -0400 Subject: [PATCH] Add -O shorthand for --omit-digest-tags to crane. --omit-digest-tags is hard to remember and easy to typo. Support -O as an alias. Signed-off-by: Scott Moser --- cmd/crane/cmd/list.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/crane/cmd/list.go b/cmd/crane/cmd/list.go index 76d71a3dc..33957d685 100644 --- a/cmd/crane/cmd/list.go +++ b/cmd/crane/cmd/list.go @@ -40,7 +40,7 @@ func NewCmdList(options *[]crane.Option) *cobra.Command { }, } cmd.Flags().BoolVar(&fullRef, "full-ref", false, "(Optional) if true, print the full image reference") - cmd.Flags().BoolVar(&omitDigestTags, "omit-digest-tags", false, "(Optional), if true, omit digest tags (e.g., ':sha256-...')") + cmd.Flags().BoolVarP(&omitDigestTags, "omit-digest-tags", "O", false, "(Optional), if true, omit digest tags (e.g., ':sha256-...')") return cmd }