parent
7decae71fc
commit
bf05975ceb
1 changed files with 5 additions and 4 deletions
|
|
@ -267,16 +267,17 @@ func determineBaseRepo(apiClient *api.Client, cmd *cobra.Command, ctx context.Co
|
|||
return ghrepo.FromFullName(repo), nil
|
||||
}
|
||||
|
||||
// TODO check to see if the git config has a default repo set; if it seems like an interactive
|
||||
// environment, ask which of the resolved remotes the user wants to use as the base. if none, let
|
||||
// them type one in. save in git config and then skip git resolution next time.
|
||||
baseOverride, err := cmd.Flags().GetString("repo")
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
remotes, err := ctx.Remotes()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
repoContext, err := context.ResolveRemotesToRepos(remotes, apiClient, "")
|
||||
repoContext, err := context.ResolveRemotesToRepos(remotes, apiClient, baseOverride)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue