Skip to content

Commit

Permalink
Docs audit: Regions and Sizes (#1487)
Browse files Browse the repository at this point in the history
* Updates region command and adds an example

* Updates the doc string for size command and adds an example

* removed typo

---------

Co-authored-by: Andrew Starr-Bochicchio <[email protected]>
  • Loading branch information
dbrian57 and andrewsomething authored Jan 9, 2024
1 parent 7f1c9db commit c10db31
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions commands/regions.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ func Region() *Command {
Use the slugs displayed by this command to specify regions in other commands.
`
CmdBuilder(cmd, RunRegionList, "list", "List datacenter regions", regionDesc,
cmdRegionList := CmdBuilder(cmd, RunRegionList, "list", "Retrieves a list of datacenter regions", regionDesc,
Writer, aliasOpt("ls"), displayerType(&displayers.Region{}))

cmdRegionList.Example = "The following example retrieves a list of regions and uses the --format flag to return only the slug for each region: doctl compute region list --format Slug"
return cmd
}

Expand Down
8 changes: 4 additions & 4 deletions commands/sizes.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,13 @@ func Size() *Command {
},
}

sizeDesc := `List the slug identifier, RAM, VCPU count, disk size, and pricing details for each Droplet size.
sizeDesc := `Retrieves a list of slug identifiers, RAM amounts, vCPU counts, disk sizes, and pricing details for each Droplet size.
Use the slugs displayed by this command to specify the type of Droplet in other commands.
Use these slugs to specify the size of Droplet in other commands, such as ` + "`" + `doctl compute droplet create <droplet-name> --size <size-slug>` + "`" + `.
`
CmdBuilder(cmd, RunSizeList, "list", "List available Droplet sizes", sizeDesc,
cmdSizeList := CmdBuilder(cmd, RunSizeList, "list", "List available Droplet sizes", sizeDesc,
Writer, aliasOpt("ls"), displayerType(&displayers.Size{}))

cmdSizeList.Example = "The following example retrieves a list of Droplet sizes and uses the --format flag to return only the slug for each size and its monthly price: doctl compute size list --format Slug,PriceMonthly"
return cmd
}

Expand Down

0 comments on commit c10db31

Please sign in to comment.