Normalize pr command arguments

This commit is contained in:
Sam Coe 2021-02-23 09:17:35 -08:00
parent c5af4ddfdc
commit 9d062ed8fc
No known key found for this signature in database
GPG key ID: 8E322C20F811D086
6 changed files with 27 additions and 9 deletions

View file

@ -35,9 +35,9 @@ func NewCmdClose(f *cmdutil.Factory, runF func(*CloseOptions) error) *cobra.Comm
}
cmd := &cobra.Command{
Use: "close {<number> | <url> | <branch>}",
Use: "close [<number> | <url> | <branch>]",
Short: "Close a pull request",
Args: cobra.ExactArgs(1),
Args: cobra.MaximumNArgs(1),
RunE: func(cmd *cobra.Command, args []string) error {
// support `-R, --repo` override
opts.BaseRepo = f.BaseRepo