Skip to content

Commit

Permalink
Updated documentation for shorter arguments.
Browse files Browse the repository at this point in the history
  • Loading branch information
qa-swaneet-sahoo committed Apr 25, 2022
1 parent 6bbb87f commit ae727b2
Show file tree
Hide file tree
Showing 10 changed files with 20 additions and 20 deletions.
4 changes: 2 additions & 2 deletions doc/generated.usage.txt
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ Flags:
--protoc Forces the use of a global protoc executable found in PATH or via --protoc-path instead of using the bundled one. If none was found, then exits with an error.
--protoc-path string Uses the given path to invoke protoc instead of searching for protoc in PATH. Also activates --protoc.
-H, --request-header string Adds the string header to the invocation of cURL. This option is not supported when --no-curl is active. E.g. -H 'MyHeader: FooBar'.
-i, --request-type string Mandatory: Package path of the Protobuf request type. E.g. mypackage.MyRequest
-o, --response-type string Mandatory: Package path of the Protobuf response type. E.g. mypackage.MyResponse
-i, --request-type string Mandatory: Message name or full package path of the Protobuf request type. The path can be shortened to '..', if the name of the request message is unique. E.g. mypackage.MyRequest or ..MyRequest
-o, --response-type string Mandatory: The Protobuf response type. See -i <request-type>
-q, --show-output-only Suppresses all output except response Protobuf as text. Overrides and deactivates -v and -D. Errors are still printed to stderr.
-u, --url string Mandatory: The url to send the request to
-v, --verbose Prints version and enables verbose output. Also activates -D.
Expand Down
4 changes: 2 additions & 2 deletions src/flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,11 @@ func intialiseFlags() {
"Infer the correct files containing the relevant protobuf messages. All proto files in the proto directory provided by -I will be used. If no -f <file> is provided, this -F is set and the files are inferred.")

flags.StringVarP(&CurrentConfig.RequestType, "request-type", "i", "",
"Mandatory: Package path of the Protobuf request type. E.g. mypackage.MyRequest")
"Mandatory: Message name or full package path of the Protobuf request type. The path can be shortened to '..', if the name of the request message is unique. E.g. mypackage.MyRequest or ..MyRequest")
AssertSuccess(rootCmd.MarkFlagRequired("request-type"))

flags.StringVarP(&CurrentConfig.ResponseType, "response-type", "o", "",
"Mandatory: Package path of the Protobuf response type. E.g. mypackage.MyResponse")
"Mandatory: The Protobuf response type. See -i <request-type>")
AssertSuccess(rootCmd.MarkFlagRequired("response-type"))

flags.StringVar(&tmpInTextType, "in", "",
Expand Down
4 changes: 2 additions & 2 deletions test/results/help-expected.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ Flags:
--protoc Forces the use of a global protoc executable found in PATH or via --protoc-path instead of using the bundled one. If none was found, then exits with an error.
--protoc-path string Uses the given path to invoke protoc instead of searching for protoc in PATH. Also activates --protoc.
-H, --request-header string Adds the string header to the invocation of cURL. This option is not supported when --no-curl is active. E.g. -H 'MyHeader: FooBar'.
-i, --request-type string Mandatory: Package path of the Protobuf request type. E.g. mypackage.MyRequest
-o, --response-type string Mandatory: Package path of the Protobuf response type. E.g. mypackage.MyResponse
-i, --request-type string Mandatory: Message name or full package path of the Protobuf request type. The path can be shortened to '..', if the name of the request message is unique. E.g. mypackage.MyRequest or ..MyRequest
-o, --response-type string Mandatory: The Protobuf response type. See -i <request-type>
-q, --show-output-only Suppresses all output except response Protobuf as text. Overrides and deactivates -v and -D. Errors are still printed to stderr.
-u, --url string Mandatory: The url to send the request to
-v, --verbose Prints version and enables verbose output. Also activates -D.
Expand Down
4 changes: 2 additions & 2 deletions test/results/help-missing-curl-expected.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ Flags:
--protoc Forces the use of a global protoc executable found in PATH or via --protoc-path instead of using the bundled one. If none was found, then exits with an error.
--protoc-path string Uses the given path to invoke protoc instead of searching for protoc in PATH. Also activates --protoc.
-H, --request-header string Adds the string header to the invocation of cURL. This option is not supported when --no-curl is active. E.g. -H 'MyHeader: FooBar'.
-i, --request-type string Mandatory: Package path of the Protobuf request type. E.g. mypackage.MyRequest
-o, --response-type string Mandatory: Package path of the Protobuf response type. E.g. mypackage.MyResponse
-i, --request-type string Mandatory: Message name or full package path of the Protobuf request type. The path can be shortened to '..', if the name of the request message is unique. E.g. mypackage.MyRequest or ..MyRequest
-o, --response-type string Mandatory: The Protobuf response type. See -i <request-type>
-q, --show-output-only Suppresses all output except response Protobuf as text. Overrides and deactivates -v and -D. Errors are still printed to stderr.
-u, --url string Mandatory: The url to send the request to
-v, --verbose Prints version and enables verbose output. Also activates -D.
Expand Down
4 changes: 2 additions & 2 deletions test/results/help-missing-curl-no-curl-expected.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ Flags:
--protoc Forces the use of a global protoc executable found in PATH or via --protoc-path instead of using the bundled one. If none was found, then exits with an error.
--protoc-path string Uses the given path to invoke protoc instead of searching for protoc in PATH. Also activates --protoc.
-H, --request-header string Adds the string header to the invocation of cURL. This option is not supported when --no-curl is active. E.g. -H 'MyHeader: FooBar'.
-i, --request-type string Mandatory: Package path of the Protobuf request type. E.g. mypackage.MyRequest
-o, --response-type string Mandatory: Package path of the Protobuf response type. E.g. mypackage.MyResponse
-i, --request-type string Mandatory: Message name or full package path of the Protobuf request type. The path can be shortened to '..', if the name of the request message is unique. E.g. mypackage.MyRequest or ..MyRequest
-o, --response-type string Mandatory: The Protobuf response type. See -i <request-type>
-q, --show-output-only Suppresses all output except response Protobuf as text. Overrides and deactivates -v and -D. Errors are still printed to stderr.
-u, --url string Mandatory: The url to send the request to
-v, --verbose Prints version and enables verbose output. Also activates -D.
Expand Down
4 changes: 2 additions & 2 deletions test/results/help-no-curl-expected.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ Flags:
--protoc Forces the use of a global protoc executable found in PATH or via --protoc-path instead of using the bundled one. If none was found, then exits with an error.
--protoc-path string Uses the given path to invoke protoc instead of searching for protoc in PATH. Also activates --protoc.
-H, --request-header string Adds the string header to the invocation of cURL. This option is not supported when --no-curl is active. E.g. -H 'MyHeader: FooBar'.
-i, --request-type string Mandatory: Package path of the Protobuf request type. E.g. mypackage.MyRequest
-o, --response-type string Mandatory: Package path of the Protobuf response type. E.g. mypackage.MyResponse
-i, --request-type string Mandatory: Message name or full package path of the Protobuf request type. The path can be shortened to '..', if the name of the request message is unique. E.g. mypackage.MyRequest or ..MyRequest
-o, --response-type string Mandatory: The Protobuf response type. See -i <request-type>
-q, --show-output-only Suppresses all output except response Protobuf as text. Overrides and deactivates -v and -D. Errors are still printed to stderr.
-u, --url string Mandatory: The url to send the request to
-v, --verbose Prints version and enables verbose output. Also activates -D.
Expand Down
4 changes: 2 additions & 2 deletions test/results/missing-args-expected.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ Flags:
--protoc Forces the use of a global protoc executable found in PATH or via --protoc-path instead of using the bundled one. If none was found, then exits with an error.
--protoc-path string Uses the given path to invoke protoc instead of searching for protoc in PATH. Also activates --protoc.
-H, --request-header string Adds the string header to the invocation of cURL. This option is not supported when --no-curl is active. E.g. -H 'MyHeader: FooBar'.
-i, --request-type string Mandatory: Package path of the Protobuf request type. E.g. mypackage.MyRequest
-o, --response-type string Mandatory: Package path of the Protobuf response type. E.g. mypackage.MyResponse
-i, --request-type string Mandatory: Message name or full package path of the Protobuf request type. The path can be shortened to '..', if the name of the request message is unique. E.g. mypackage.MyRequest or ..MyRequest
-o, --response-type string Mandatory: The Protobuf response type. See -i <request-type>
-q, --show-output-only Suppresses all output except response Protobuf as text. Overrides and deactivates -v and -D. Errors are still printed to stderr.
-u, --url string Mandatory: The url to send the request to
-v, --verbose Prints version and enables verbose output. Also activates -D.
Expand Down
4 changes: 2 additions & 2 deletions test/results/missing-args-no-curl-expected.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ Flags:
--protoc Forces the use of a global protoc executable found in PATH or via --protoc-path instead of using the bundled one. If none was found, then exits with an error.
--protoc-path string Uses the given path to invoke protoc instead of searching for protoc in PATH. Also activates --protoc.
-H, --request-header string Adds the string header to the invocation of cURL. This option is not supported when --no-curl is active. E.g. -H 'MyHeader: FooBar'.
-i, --request-type string Mandatory: Package path of the Protobuf request type. E.g. mypackage.MyRequest
-o, --response-type string Mandatory: Package path of the Protobuf response type. E.g. mypackage.MyResponse
-i, --request-type string Mandatory: Message name or full package path of the Protobuf request type. The path can be shortened to '..', if the name of the request message is unique. E.g. mypackage.MyRequest or ..MyRequest
-o, --response-type string Mandatory: The Protobuf response type. See -i <request-type>
-q, --show-output-only Suppresses all output except response Protobuf as text. Overrides and deactivates -v and -D. Errors are still printed to stderr.
-u, --url string Mandatory: The url to send the request to
-v, --verbose Prints version and enables verbose output. Also activates -D.
Expand Down
4 changes: 2 additions & 2 deletions test/results/missing-args-partial-expected.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ Flags:
--protoc Forces the use of a global protoc executable found in PATH or via --protoc-path instead of using the bundled one. If none was found, then exits with an error.
--protoc-path string Uses the given path to invoke protoc instead of searching for protoc in PATH. Also activates --protoc.
-H, --request-header string Adds the string header to the invocation of cURL. This option is not supported when --no-curl is active. E.g. -H 'MyHeader: FooBar'.
-i, --request-type string Mandatory: Package path of the Protobuf request type. E.g. mypackage.MyRequest
-o, --response-type string Mandatory: Package path of the Protobuf response type. E.g. mypackage.MyResponse
-i, --request-type string Mandatory: Message name or full package path of the Protobuf request type. The path can be shortened to '..', if the name of the request message is unique. E.g. mypackage.MyRequest or ..MyRequest
-o, --response-type string Mandatory: The Protobuf response type. See -i <request-type>
-q, --show-output-only Suppresses all output except response Protobuf as text. Overrides and deactivates -v and -D. Errors are still printed to stderr.
-u, --url string Mandatory: The url to send the request to
-v, --verbose Prints version and enables verbose output. Also activates -D.
Expand Down
4 changes: 2 additions & 2 deletions test/results/missing-args-partial-no-curl-expected.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ Flags:
--protoc Forces the use of a global protoc executable found in PATH or via --protoc-path instead of using the bundled one. If none was found, then exits with an error.
--protoc-path string Uses the given path to invoke protoc instead of searching for protoc in PATH. Also activates --protoc.
-H, --request-header string Adds the string header to the invocation of cURL. This option is not supported when --no-curl is active. E.g. -H 'MyHeader: FooBar'.
-i, --request-type string Mandatory: Package path of the Protobuf request type. E.g. mypackage.MyRequest
-o, --response-type string Mandatory: Package path of the Protobuf response type. E.g. mypackage.MyResponse
-i, --request-type string Mandatory: Message name or full package path of the Protobuf request type. The path can be shortened to '..', if the name of the request message is unique. E.g. mypackage.MyRequest or ..MyRequest
-o, --response-type string Mandatory: The Protobuf response type. See -i <request-type>
-q, --show-output-only Suppresses all output except response Protobuf as text. Overrides and deactivates -v and -D. Errors are still printed to stderr.
-u, --url string Mandatory: The url to send the request to
-v, --verbose Prints version and enables verbose output. Also activates -D.
Expand Down

0 comments on commit ae727b2

Please sign in to comment.