Skip to content

Commit 27dbb16

Browse files
authored
fix!: remove the --verbose flag for all related commands (#1276)
Pending on #1260 This PR removed the `--verbose` flag support as proposed in #1260. Resolve part of #1247 --------- Signed-off-by: Junjie Gao <junjiegao@microsoft.com>
1 parent 083e73d commit 27dbb16

20 files changed

Lines changed: 68 additions & 88 deletions

File tree

cmd/notation/internal/flag/options.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -59,22 +59,18 @@ func (opts *SignerFlagOpts) ApplyFlagsToCommand(command *cobra.Command) {
5959

6060
// LoggingFlagOpts cmd opts for logging.
6161
type LoggingFlagOpts struct {
62-
Debug bool
63-
Verbose bool
62+
Debug bool
6463
}
6564

6665
// ApplyFlags applies flags to a command flag set.
6766
func (opts *LoggingFlagOpts) ApplyFlags(fs *pflag.FlagSet) {
6867
fs.BoolVarP(&opts.Debug, "debug", "d", false, "debug mode")
69-
fs.BoolVarP(&opts.Verbose, "verbose", "v", false, "verbose mode")
7068
}
7169

7270
// InitializeLogger sets up the logger based on common options.
7371
func (opts *LoggingFlagOpts) InitializeLogger(ctx context.Context) context.Context {
7472
if opts.Debug {
7573
ctx = trace.WithLoggerLevel(ctx, logrus.DebugLevel)
76-
} else if opts.Verbose {
77-
ctx = trace.WithLoggerLevel(ctx, logrus.InfoLevel)
7874
} else {
7975
return ctx
8076
}

specs/cmd/blob.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,6 @@ Flags:
9292
--timestamp-root-cert string filepath of timestamp authority root certificate
9393
--timestamp-url string RFC 3161 Timestamping Authority (TSA) server URL
9494
-m, --user-metadata stringArray {key}={value} pairs that are added to the signature payload
95-
-v, --verbose verbose mode
9695
```
9796

9897
### notation blob inspect
@@ -106,7 +105,6 @@ Usage:
106105
Flags:
107106
-o, --output string output format, options: 'json', 'tree' (default "tree")
108107
-d, --debug debug mode
109-
-v, --verbose verbose mode
110108
-h, --help help for inspect
111109
```
112110

@@ -185,7 +183,6 @@ Flags:
185183
--policy-name string policy name to verify against. If not provided, the global policy is used if exists
186184
-s --signature string filepath of the signature to be verified
187185
-m, --user-metadata stringArray user defined {key}={value} pairs that must be present in the signature for successful verification if provided
188-
-v, --verbose verbose mode
189186
```
190187

191188
## Usage

specs/cmd/certificate.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,6 @@ Flags:
9090
-h, --help help for list
9191
-s, --store string specify named store
9292
-t, --type string specify trust store type, options: ca, signingAuthority, tsa
93-
-v, --verbose verbose mode
9493
```
9594

9695
### notation certificate show
@@ -106,7 +105,6 @@ Flags:
106105
-h, --help help for show
107106
-s, --store string specify named store
108107
-t, --type string specify trust store type, options: ca, signingAuthority, tsa
109-
-v, --verbose verbose mode
110108
```
111109

112110
### notation certificate delete

specs/cmd/inspect.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ Flags:
4545
-o, --output string output format, options: 'json', 'tree' (default "tree")
4646
-p, --password string password for registry operations (default to $NOTATION_PASSWORD if not specified)
4747
-u, --username string username for registry operations (default to $NOTATION_USERNAME if not specified)
48-
-v, --verbose verbose mode
4948
```
5049

5150
## Usage

specs/cmd/key.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ Flags:
3939
--id string key id (required if --plugin is set)
4040
--plugin string signing plugin name
4141
--plugin-config stringArray {key}={value} pairs that are passed as it is to a plugin, refer plugin's documentation to set appropriate values
42-
-v, --verbose verbose mode
4342
```
4443

4544
### notation key delete
@@ -53,7 +52,6 @@ Usage:
5352
Flags:
5453
-d, --debug debug mode
5554
-h, --help help for delete
56-
-v, --verbose verbose mode
5755
```
5856

5957
### notation key list
@@ -86,7 +84,6 @@ Flags:
8684
-d, --debug debug mode
8785
--default mark as default
8886
-h, --help help for update
89-
-v, --verbose verbose mode
9087
```
9188

9289
## Usage

specs/cmd/list.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ Flags:
3434
--oci-layout [Experimental] list signatures stored in OCI image layout
3535
-p, --password string password for registry operations (default to $NOTATION_PASSWORD if not specified)
3636
-u, --username string username for registry operations (default to $NOTATION_USERNAME if not specified)
37-
-v, --verbose verbose mode
3837
```
3938

4039
## Usage

specs/cmd/login.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ Flags:
1919
-p, --password string password for registry operations (default to $NOTATION_PASSWORD if not specified)
2020
--password-stdin take the password from stdin
2121
-u, --username string username for registry operations (default to $NOTATION_USERNAME if not specified)
22-
-v, --verbose verbose mode
2322
```
2423

2524
## Usage

specs/cmd/logout.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ Usage:
1515
Flags:
1616
-d, --debug debug mode
1717
-h, --help help for logout
18-
-v, --verbose verbose mode
1918
```
2019

2120
## Usage

specs/cmd/plugin.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@ Flags:
5353
-h, --help help for install
5454
--sha256sum string must match SHA256 of the plugin source, required when "--url" flag is set
5555
--url install plugin from an HTTPS URL. The plugin download timeout is 10m0s
56-
-v, --verbose verbose mode
5756
5857
Aliases:
5958
install, add
@@ -70,7 +69,6 @@ Usage:
7069
Flags:
7170
-d, --debug debug mode
7271
-h, --help help for remove
73-
-v, --verbose verbose mode
7472
-y, --yes do not prompt for confirmation
7573
Aliases:
7674
uninstall, remove, rm

specs/cmd/sign.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ Flags:
4646
--timestamp-url string RFC 3161 Timestamping Authority (TSA) server URL
4747
-u, --username string username for registry operations (default to $NOTATION_USERNAME if not specified)
4848
-m, --user-metadata stringArray {key}={value} pairs that are added to the signature payload
49-
-v, --verbose verbose mode
5049
```
5150

5251
### Set config property for OCI image manifest

0 commit comments

Comments
 (0)