Skip to content

Commit

Permalink
feat: add -X as a shorthand for --method in HTTP (#120)
Browse files Browse the repository at this point in the history
  • Loading branch information
radulucut authored Jul 19, 2024
1 parent 2edb712 commit c73170e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/http.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ Examples:
flags.StringVar(&r.ctx.Host, "host", r.ctx.Host, "specify the Host header to add to the request (default host's defined in command target)")
flags.StringVar(&r.ctx.Path, "path", r.ctx.Path, "specify the URL pathname (default \"/\")")
flags.StringVar(&r.ctx.Query, "query", r.ctx.Query, "specify a query string to add")
flags.StringVar(&r.ctx.Method, "method", r.ctx.Method, "specify the HTTP method to use: HEAD or GET (default \"HEAD\")")
flags.StringVarP(&r.ctx.Method, "method", "X", r.ctx.Method, "specify the HTTP method to use: HEAD or GET (default \"HEAD\")")
flags.StringArrayVarP(&r.ctx.Headers, "header", "H", r.ctx.Headers, "add HTTP headers to the request in the format \"Key: Value\"; to add multiple headers, define the flag for each one separately")
flags.BoolVar(&r.ctx.Full, "full", r.ctx.Full, "enable full output when performing an HTTP GET request to display the status, headers, and body")

Expand Down

0 comments on commit c73170e

Please sign in to comment.