Skip to content

Commit 45beb32

Browse files
committed
tmp
1 parent 5c28cf9 commit 45beb32

1 file changed

Lines changed: 39 additions & 6 deletions

File tree

  • cmd/carapace-spec-botocore/cmd

cmd/carapace-spec-botocore/cmd/root.go

Lines changed: 39 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -185,14 +185,47 @@ func parseService(name, folder string) command.Command {
185185
subCmd.Documentation.Flag = make(map[string]string)
186186

187187
// custom flags added by awscli
188-
subCmd.AddFlag(command.Flag{Longhand: "--cli-input-json", Usage: "Read arguments from the JSON string provided", Value: true})
189-
subCmd.AddFlag(command.Flag{Longhand: "--cli-input-yaml", Usage: "Read arguments from the YAML string provided", Value: true})
190-
subCmd.AddFlag(command.Flag{Longhand: "--generate-cli-skeleton", Usage: "Prints a JSON skeleton to standard output without sending an API request"})
188+
subCmd.AddFlag(command.Flag{Longhand: "--cli-input-json", Usage: "Read arguments from the JSON string provided.", Value: true})
189+
subCmd.AddFlag(command.Flag{Longhand: "--cli-input-yaml", Usage: "Read arguments from the YAML string provided.", Value: true})
190+
subCmd.AddFlag(command.Flag{Longhand: "--generate-cli-skeleton", Usage: "Prints a JSON skeleton to standard output without sending an API request."})
191+
192+
subCmd.Documentation.Flag["cli-input-json"] = `Reads arguments from the JSON string provided.
193+
The JSON string follows the format provided by --generate-cli-skeleton.
194+
If other arguments are provided on the command line, those values will override the JSON-provided values.
195+
It is not possible to pass arbitrary binary values using a JSON-provided value as the string will be taken literally.
196+
This may not be specified along with --cli-input-yaml.`
197+
subCmd.Documentation.Flag["cli-input-yaml"] = `Reads arguments from the JSON string provided.
198+
The JSON string follows the format provided by --generate-cli-skeleton.
199+
If other arguments are provided on the command line, those values will override the JSON-provided values.
200+
It is not possible to pass arbitrary binary values using a JSON-provided value as the string will be taken literally.
201+
This may not be specified along with --cli-input-yaml.`
202+
subCmd.Documentation.Flag["generate-cli-skeleton"] = `If other arguments are provided on the command line, those values will override the JSON-provided values. It is not possible to pass arbitrary binary values using a JSON-provided value as the string will be taken literally.
203+
This may not be specified along with --cli-input-yaml.`
204+
191205
if paginator, ok := paginators[name]; ok {
192-
subCmd.AddFlag(command.Flag{Longhand: "--max-items", Usage: "TODO", Value: true})
193-
subCmd.AddFlag(command.Flag{Longhand: "--starting-token", Usage: "TODO", Value: true})
206+
subCmd.AddFlag(command.Flag{Longhand: "--max-items", Usage: "The total number of items to return in the command's output.", Value: true})
207+
subCmd.AddFlag(command.Flag{Longhand: "--starting-token", Usage: "A token to specify where to start paginating.", Value: true})
208+
209+
subCmd.Documentation.Flag["max-items"] = `The total number of items to return in the command's output.
210+
If the total number of items available is more than the value specified, a NextToken is provided in the command's output.
211+
To resume pagination, provide the NextToken value in the starting-token argument of a subsequent command.
212+
Do not use the NextToken response element directly outside of the AWS CLI.
213+
214+
For usage examples, see Pagination in the AWS Command Line Interface User Guide.`
215+
subCmd.Documentation.Flag["starting-token"] = `A token to specify where to start paginating.
216+
This is the NextToken from a previously truncated response.
217+
218+
For usage examples, see Pagination in the AWS Command Line Interface User Guide.`
219+
194220
if paginator.LimitKey != nil {
195-
subCmd.AddFlag(command.Flag{Longhand: "--page-size", Usage: "TODO", Value: true})
221+
subCmd.AddFlag(command.Flag{Longhand: "--page-size", Usage: "The size of each page to get in the AWS service call.", Value: true})
222+
223+
subCmd.Documentation.Flag["page-size"] = `The size of each page to get in the AWS service call.
224+
This does not affect the number of items returned in the command's output.
225+
Setting a smaller page size results in more calls to the AWS service, retrieving fewer items in each call.
226+
This can help prevent the AWS service calls from timing out.
227+
228+
For usage examples, see Pagination in the AWS Command Line Interface User Guide.`
196229
}
197230
}
198231

0 commit comments

Comments
 (0)