Group issue commands into general vs. additional
This commit is contained in:
parent
4d0206510a
commit
9971c12bed
4 changed files with 11 additions and 3 deletions
|
|
@ -63,6 +63,7 @@ func NewCmdCreate(f *cmdutil.Factory, runF func(*CreateOptions) error) *cobra.Co
|
|||
`),
|
||||
Args: cmdutil.NoArgsQuoteReminder,
|
||||
Aliases: []string{"new"},
|
||||
GroupID: "general",
|
||||
RunE: func(cmd *cobra.Command, args []string) error {
|
||||
// support `-R, --repo` override
|
||||
opts.BaseRepo = f.BaseRepo
|
||||
|
|
|
|||
|
|
@ -41,6 +41,11 @@ func NewCmdIssue(f *cmdutil.Factory) *cobra.Command {
|
|||
|
||||
cmdutil.EnableRepoOverride(cmd, f)
|
||||
|
||||
cmd.AddGroup(&cobra.Group{
|
||||
ID: "general",
|
||||
Title: "General commands",
|
||||
})
|
||||
|
||||
cmd.AddCommand(cmdClose.NewCmdClose(f, nil))
|
||||
cmd.AddCommand(cmdCreate.NewCmdCreate(f, nil))
|
||||
cmd.AddCommand(cmdList.NewCmdList(f, nil))
|
||||
|
|
|
|||
|
|
@ -73,6 +73,7 @@ func NewCmdList(f *cmdutil.Factory, runF func(*ListOptions) error) *cobra.Comman
|
|||
$ gh issue list --search "error no:assignee sort:created-asc"
|
||||
`),
|
||||
Aliases: []string{"ls"},
|
||||
GroupID: "general",
|
||||
Args: cmdutil.NoArgsQuoteReminder,
|
||||
RunE: func(cmd *cobra.Command, args []string) error {
|
||||
// support `-R, --repo` override
|
||||
|
|
|
|||
|
|
@ -32,9 +32,10 @@ func NewCmdStatus(f *cmdutil.Factory, runF func(*StatusOptions) error) *cobra.Co
|
|||
}
|
||||
|
||||
cmd := &cobra.Command{
|
||||
Use: "status",
|
||||
Short: "Show status of relevant issues",
|
||||
Args: cmdutil.NoArgsQuoteReminder,
|
||||
Use: "status",
|
||||
Short: "Show status of relevant issues",
|
||||
GroupID: "general",
|
||||
Args: cmdutil.NoArgsQuoteReminder,
|
||||
RunE: func(cmd *cobra.Command, args []string) error {
|
||||
// support `-R, --repo` override
|
||||
opts.BaseRepo = f.BaseRepo
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue