-
Notifications
You must be signed in to change notification settings - Fork 84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CLOUDP-303333 Improve --file description for auto-generated commands #3709
Conversation
APIx Bot |
@@ -60,7 +60,7 @@ jobs: | |||
if: env.review_needed == 'true' && steps.append_comment.outputs.previous_comment_id == '' | |||
env: | |||
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL_DOCS }} | |||
SLACK_WEBHOOK_TYPE: INCOMING_WEBHOOK |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should fix docs bot messages
internal/cli/api/api.go
Outdated
@@ -253,7 +253,7 @@ func convertAPIToCobraCommand(command api.Command) (*cobra.Command, error) { | |||
addVersionFlag(cmd, command, &version) | |||
|
|||
if needsFileFlag(command) { | |||
cmd.Flags().StringVar(&file, flag.File, "", "path to the file which contains the api request contents") | |||
cmd.Flags().StringVar(&file, flag.File, "", "path to the file which contains the api request contents, alternatively you may pass standard input") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about this:
Path to your API request file. Leave empty to use stdin instead - you must provide one or the other, but not both.
The main reason we're changing this sentence is to:
- Make it clear that either file or stdin is required
- Make it clear that you have to provide one or the other but not both
That was the main feedback we got from the docs team.
Coverage Report 📈
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Proposed changes
Improve --file description for auto-generated commands
Jira ticket: CLOUDP-303333
Closes #[issue number]
Checklist
make fmt
and formatted my codeFurther comments