Merge pull request #7 from ravocean/trunk

Added flags: --settings, --projects, and --wiki
This commit is contained in:
Husrav Homidov 2021-05-23 16:02:51 -07:00 committed by GitHub
commit aa7acb7272
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -24,6 +24,10 @@ type BrowseOptions struct {
SelectorArg string
FileArg string // Used for storing the file path
NumberArg int // Used for storing pull request number
ProjectsFlag bool
WikiFlag bool
SettingsFlag bool
}
func NewCmdBrowse(f *cmdutil.Factory) *cobra.Command {
@ -49,6 +53,10 @@ func NewCmdBrowse(f *cmdutil.Factory) *cobra.Command {
},
}
cmd.Flags().BoolVarP(&opts.ProjectsFlag, "projects", "p", false, "Open projects tab in browser")
cmd.Flags().BoolVarP(&opts.WikiFlag, "wiki", "w", false, "Opens the wiki in browser")
cmd.Flags().BoolVarP(&opts.SettingsFlag, "settings", "s", false, "Opens the settings in browse")
return cmd
}
@ -86,11 +94,3 @@ func parseArgs(opts *BrowseOptions) {
}
}
}
func parseFlags(opts *BrowseOptions) {
}
//hello
//making pull request