tea pr create: make local repo optional #393

Merged
6543 merged 7 commits from noerw/tea:fix-378 into master 2021-09-22 15:48:21 +00:00
Member

this is a partial fix to #378, making the command available outside of a local repo.

new behaviour:

  • when run interactively without local repo context, the head repo prompt is not pre-populated
  • when run with flags without local repo context, it will complain unless --head is specified
this is a partial fix to #378, making the command available outside of a local repo. new behaviour: - when run interactively without local repo context, the head repo prompt is not pre-populated - when run with flags without local repo context, it will complain unless `--head` is specified
noerw added this to the v0.8.0 milestone 2021-08-25 08:30:13 +00:00
noerw added the
kind
enhancement
label 2021-08-25 08:30:13 +00:00
noerw added 1 commit 2021-08-25 08:30:14 +00:00
pr create: make local repo optional
All checks were successful
continuous-integration/drone/pr Build is passing
3d7e86575c
noerw reviewed 2021-08-25 10:41:59 +00:00
@ -41,2 +38,3 @@
promptOpts := survey.WithValidator(survey.Required)
headOwner, headBranch, err := task.GetDefaultPRHead(localRepo)
// TODO: can't we use TeaContext.LocalRepo for this?
Author
Member

I think passing context.TeaContext instead of config.Login in this method would be convenient, as TeaContext already contains the local repo when available.
@6543 In the past you opposed importing modules/context in modules/interact, wdytn?

I think passing `context.TeaContext` instead of `config.Login` in this method would be convenient, as TeaContext already contains the local repo when available. @6543 In the past you opposed importing `modules/context` in `modules/interact`, wdytn?
Member

see no obstacles to use context.TeaContext, but will wait @6543

see no obstacles to use `context.TeaContext`, but will wait @6543
Owner

added refactor

added refactor
6543 marked this conversation as resolved
noerw added 1 commit 2021-09-05 16:28:04 +00:00
Merge branch 'master' into fix-378
All checks were successful
continuous-integration/drone/pr Build is passing
f25be4a13c
6543 added 1 commit 2021-09-06 10:53:19 +00:00
Merge branch 'master' into fix-378
All checks were successful
continuous-integration/drone/pr Build is passing
816b31472f
axifive approved these changes 2021-09-11 16:48:28 +00:00
6543 added 1 commit 2021-09-22 00:09:09 +00:00
refactor: use TeaContext
All checks were successful
continuous-integration/drone/pr Build is passing
9a6802d911
6543 added 1 commit 2021-09-22 00:12:24 +00:00
Merge branch 'master' into fix-378
All checks were successful
continuous-integration/drone/pr Build is passing
6fadc4ca88
6543 added 2 commits 2021-09-22 00:38:23 +00:00
use more TeaContext
All checks were successful
continuous-integration/drone/pr Build is passing
26c39c88a6
Owner

@noerw can you test - this should now close #378

@noerw can you test - this should now close #378
6543 approved these changes 2021-09-22 00:39:39 +00:00
Author
Member

your changes lgtm. wrt to the refactor, lets do the rest later → #402

your changes lgtm. wrt to the refactor, lets do the rest later → #402
6543 merged commit 7b7c7f57be into master 2021-09-22 15:48:21 +00:00
6543 added the
kind
refactor
label 2021-09-22 15:48:31 +00:00
6543 deleted branch fix-378 2021-09-22 15:48:37 +00:00
Sign in to join this conversation.
No description provided.