Skip to content

Commit 9ca96e3

Browse files
author
jmccormick2001
committed
make --output description better, make json the default flag value
1 parent c38d616 commit 9ca96e3

File tree

4 files changed

+10
-10
lines changed

4 files changed

+10
-10
lines changed

hugo/content/getting-started/_index.adoc

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,8 @@ $ pgo status [FLAGS]
5757
|=========================================================
5858
|Name |Shorthand |Input |Usage
5959

60-
|`--output` |-o |String |
61-
The output format. Currently, JSON is supported.
60+
|`--output=json` |-o json|String |
61+
The output format. Currently, *json* is the only supported value.
6262
|=========================================================
6363

6464
=== Operator Configuration
@@ -405,8 +405,8 @@ $ pgo show cluster NAME|all [FLAGS]
405405
|=========================================================
406406
|Name |Shorthand |Input |Usage
407407

408-
|`--output` |-o |String |
409-
The output format. Currently, JSON is supported.
408+
|`--output=json` |-o json |String |
409+
The output format. Currently, *json* is the only supported value.
410410

411411
|`--selector` |-s |String |
412412
The selector to use for cluster filtering.
@@ -482,8 +482,8 @@ $ pgo test NAME|all [FLAGS]
482482
|=========================================================
483483
|Name |Shorthand |Input |Usage
484484

485-
|`--output` |-o |String |
486-
The output format. Currently, JSON is supported.
485+
|`--output=json` |-o json |String |
486+
The output format. Currently, *json* is the only supported value.
487487

488488
|`--selector` |-s |String |
489489
The selector to use for cluster filtering.

pgo/cmd/show.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ func init() {
9797

9898
ShowBackupCmd.Flags().StringVarP(&BackupType, "backup-type", "", util.LABEL_BACKUP_TYPE_BASEBACKUP, "The backup type output to list. Valid choices are pgbasebackup (default) or pgbackrest.")
9999
ShowClusterCmd.Flags().StringVarP(&CCPImageTag, "ccp-image-tag", "", "", "Filter the results based on the image tag of the cluster.")
100-
ShowClusterCmd.Flags().StringVarP(&OutputFormat, "output", "o", "", "The output format. Currently, JSON is supported.")
100+
ShowClusterCmd.Flags().StringVarP(&OutputFormat, "output", "o", "json", "The output format. Currently, json is the only supported value.")
101101
ShowClusterCmd.Flags().StringVarP(&Selector, "selector", "s", "", "The selector to use for cluster filtering.")
102102
ShowPVCCmd.Flags().StringVarP(&PVCRoot, "pvc-root", "", "", "The PVC directory to list.")
103103
ShowScheduleCmd.Flags().StringVarP(&Selector, "selector", "s", "", "The selector to use for cluster filtering.")

pgo/cmd/status.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ var Summary bool
4343
func init() {
4444
RootCmd.AddCommand(statusCmd)
4545

46-
statusCmd.Flags().StringVarP(&OutputFormat, "output", "o", "", "The output format. Currently, JSON is supported.")
46+
statusCmd.Flags().StringVarP(&OutputFormat, "output", "o", "json", "The output format. Currently, json is the only supported value.")
4747

4848
}
4949

pgo/cmd/test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ var testCmd = &cobra.Command{
3939
fmt.Println(`Error: You must specify the name of the clusters to test.`)
4040
} else {
4141
if OutputFormat != "" && OutputFormat != "json" {
42-
fmt.Println("Error: Only JSON is currently supported for the --output flag value.")
42+
fmt.Println("Error: Only 'json' is currently supported for the --output flag value.")
4343
os.Exit(2)
4444
}
4545
showTest(args)
@@ -50,7 +50,7 @@ var testCmd = &cobra.Command{
5050
func init() {
5151
RootCmd.AddCommand(testCmd)
5252
testCmd.Flags().StringVarP(&Selector, "selector", "s", "", "The selector to use for cluster filtering.")
53-
testCmd.Flags().StringVarP(&OutputFormat, "output", "o", "", "The output format. Currently, JSON is supported.")
53+
testCmd.Flags().StringVarP(&OutputFormat, "output", "o", "json", "The output format. Currently, json is the only supported value.")
5454
}
5555

5656
func showTest(args []string) {

0 commit comments

Comments
 (0)