diff --git a/config/config_parser/remote_branch.go b/config/config_parser/remote_branch.go index 45b89f5..6273cec 100644 --- a/config/config_parser/remote_branch.go +++ b/config/config_parser/remote_branch.go @@ -17,7 +17,7 @@ func NewRemoteBranchSource(gitcmd git.GitInterface) *remoteBranch { } } -var _remoteBranchRegex = regexp.MustCompile(`^## ([a-zA-Z0-9_\-/\.]+)\.\.\.([a-zA-Z0-9_\-/\.]+)/([a-zA-Z0-9_\-/\.]+)`) +var _remoteBranchRegex = regexp.MustCompile(`^## ([a-zA-Z0-9_\-/\.]+)\.\.\.([a-zA-Z0-9_\-\.]+)/([a-zA-Z0-9_\-/\.]+)`) func (s *remoteBranch) Load(cfg interface{}) { var output string @@ -32,5 +32,7 @@ func (s *remoteBranch) Load(cfg interface{}) { repoCfg := cfg.(*config.RepoConfig) repoCfg.GitHubRemote = matches[2] - repoCfg.GitHubBranch = matches[3] + if repoCfg.GitHubBranch == "" { + repoCfg.GitHubBranch = matches[3] + } }