Skip to content

Commit

Permalink
default output format table (#52)
Browse files Browse the repository at this point in the history
* default output format table

* ensure readme default is correct
  • Loading branch information
aegershman authored Nov 25, 2019
1 parent 56a3914 commit 0db5ffe
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ cf usage-report
cf usage-report -o myorg
cf usage-report -o firstorg -o secondorg [-o orgName...]

# report using different formats ("string" is default)
# report using different formats
cf usage-report -o firstorg -o secondorg --format string
cf usage-report -o firstorg -o secondorg --format table
```
Expand Down
6 changes: 3 additions & 3 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ func (cmd *UsageReportCmd) GetMetadata() plugin.PluginMetadata {
Name: "usage-report",
HelpText: "View AIs, SIs and memory usage for orgs and spaces",
UsageDetails: plugin.Usage{
Usage: "cf usage-report [-o orgName...] --format string",
Usage: "cf usage-report [-o orgName...] --format formatChoice",
Options: map[string]string{
"o": "organization(s) included in report. Flag can be provided multiple times.",
"format": "format to print as (options: string,table) (default: string)",
"format": "format to print as (options: string,table) (default: table)",
"log-level": "(options: info,debug,trace) (default: info)",
},
},
Expand All @@ -66,7 +66,7 @@ func (cmd *UsageReportCmd) UsageReportCommand(args []string) {

flagss := flag.NewFlagSet(args[0], flag.ContinueOnError)
flagss.Var(&userFlags, "o", "")
flagss.StringVar(&formatFlag, "format", "string", "")
flagss.StringVar(&formatFlag, "format", "table", "")
flagss.StringVar(&logLevelFlag, "log-level", "info", "")
err := flagss.Parse(args[1:])
if err != nil {
Expand Down

0 comments on commit 0db5ffe

Please sign in to comment.