Documentation ¶
Index ¶
Constants ¶
View Source
const ( DEFAULT_BRANCH_NAME = "master" DEFAULT_PR_FILE_NAME = "PULLREQ_EDITMSG" DEFAULT_CS = "#" )
View Source
const (
DEFAULT_RELEASE_FILE_NAME = "RELEASE_EDITMSG"
)
Variables ¶
View Source
var RootCmd = &cobra.Command{ Use: "hlb", Short: "multi git hosting service manager", Long: ``, PersistentPreRun: func(cmd *cobra.Command, args []string) { bypassCmds := []string{"create", "version", "init", "add-service"} configFilePath, err := etc.GetConfigDirPath() if err != nil { etc.PanicIfErrorExist(err) } for _, bypassCmd := range bypassCmds { if bypassCmd == cmd.Name() { return } } var config etc.Config err = viper.Unmarshal(&config) etc.PanicIfErrorExist(err) remote, err := git.GetDefaultRemote(".") etc.PanicIfErrorExist(err) serviceConfig, ok := config.FindServiceConfig(remote.ServiceHost) if !ok { fmt.Println(remote.ServiceHost, "is unknown host. Please add the service configuration to config file("+configFilePath+")") os.Exit(1) } if serviceConfig.Token == "" { serviceUrl := serviceConfig.Protocol + "://" + serviceConfig.Host addServiceCmd.Run(cmd, []string{serviceConfig.Type, serviceUrl}) } }, }
RootCmd represents the base command when called without any subcommands
Functions ¶
Types ¶
This section is empty.
Source Files ¶
- add-service.go
- browse.go
- browse_boards.go
- browse_commits.go
- browse_issues.go
- browse_mergerequests.go
- browse_milestones.go
- browse_projects.go
- browse_pullrequests.go
- browse_wikis.go
- create.go
- create_pullrequest.go
- create_release.go
- ibrowse.go
- init.go
- list.go
- list_issues.go
- list_pullrequests.go
- pull-request.go
- release.go
- root.go
- selfupdate.go
- version.go
Click to show internal directories.
Click to hide internal directories.