Commit graph

206 commits

Author SHA1 Message Date
Mislav Marohnić
2b9de23637 Extract alias expansion into a separate package 2020-08-11 15:18:48 +02:00
Mislav Marohnić
172ea2b078 Isolate all alias commands 2020-08-11 13:57:48 +02:00
Mislav Marohnić
3c55b29446 🔥 colorableOut 2020-08-07 17:02:24 +02:00
Mislav Marohnić
7f6d687629 Isolate config command 2020-08-07 16:59:23 +02:00
Mislav Marohnić
d933cd91d4 Migrate completion command 2020-08-07 15:22:49 +02:00
Mislav Marohnić
47cef736f4 Fix GH_REPO override 2020-08-07 14:47:58 +02:00
Mislav Marohnić
aef1a4ba4d Extract root command and factory logic into separate packages 2020-08-07 14:40:33 +02:00
Mislav Marohnić
5e24e0d9b9 🔥 unused legacy helpers 2020-08-07 00:48:50 +02:00
Mislav Marohnić
34cc84c1e0 Provide consistent factory functions for top-level commands 2020-08-07 00:45:45 +02:00
Mislav Marohnić
c00fe73d5a Isolate issue commands 2020-08-07 00:27:55 +02:00
Mislav Marohnić
5404fb2362 Wrap up migrating all pr commands 2020-08-06 21:21:35 +02:00
Mislav Marohnić
82661c197e Isolate pr list command 2020-08-04 18:38:06 +02:00
Mislav Marohnić
558e3f3dea Isolate pr create command 2020-08-04 18:29:42 +02:00
Mislav Marohnić
d774a6a35f Merge branch 'pr-commands-isolate' into pr-commands-isolate-2 2020-08-04 15:13:33 +02:00
Mislav Marohnić
a73584db72 Merge remote-tracking branch 'origin' into pr-commands-isolate 2020-08-04 15:01:30 +02:00
Mislav Marohnić
3ac73297eb Isolate pr status command 2020-07-31 19:07:30 +02:00
Mislav Marohnić
7cc74c5bb6 Isolate pr merge command 2020-07-31 19:07:16 +02:00
Mislav Marohnić
74b191d0f7 Isolate pr view command 2020-07-31 14:19:09 +02:00
Mislav Marohnić
487dd06bf3 Isolate pr checkout command 2020-07-29 22:50:34 +02:00
Mislav Marohnić
af68a749f0 Isolate pr diff command 2020-07-29 22:49:50 +02:00
Mislav Marohnić
12637d02d6 Isolate pr review command 2020-07-29 19:35:54 +02:00
Mislav Marohnić
c0b116b511 Merge remote-tracking branch 'origin' into ghe-api 2020-07-28 18:12:47 +02:00
Nate Smith
f486cc4823
Merge pull request #1435 from cli/repo-cleanup
final isolation repo cleanup
2020-07-28 10:54:09 -05:00
Mislav Marohnić
07eb1e7592 Document GLAMOUR_STYLE support 2020-07-28 15:24:41 +02:00
vilmibm
29f4453e07 final repo command cleanup 2020-07-27 14:09:07 -05:00
vilmibm
9359dcaf80 isolate credits 2020-07-27 13:56:15 -05:00
Mislav Marohnić
dd0d236629 Merge remote-tracking branch 'origin' into ghe-api 2020-07-27 20:13:54 +02:00
vilmibm
f3eb092d7e isolate repo fork command and tweak usage
This commit is another isolation refactor, this time for repo fork.
However, I got fed up with the --remote="true|false|prompt" style of
flags and took this opportunity to switch to a set of bool flags:

--remote and --clone
--no-remote and --no-clone

the string args were really non standard and confusing; with only two
bools it was impossible to tell when to prompt.
2020-07-27 13:04:31 -05:00
Mislav Marohnić
0cbcf8a7fa Merge remote-tracking branch 'origin' into ghe-api 2020-07-27 16:30:20 +02:00
vilmibm
c34054bdc8 isolate repo create command 2020-07-24 12:26:27 -05:00
vilmibm
1831d95433 isolated clone command
This commit hacks the existing repo clone tests into something usable by
the new isolated command. It went ok and was less effort than trying to
introduce the same kind of test format as repo view and gist create.
2020-07-23 16:40:31 -05:00
Mislav Marohnić
288d01318b Respect the hostname of current repository in queries 2020-07-23 22:31:08 +02:00
vilmibm
b9ce1a1daf pass resolving baserepo into newcmdview 2020-07-23 15:13:23 -05:00
vilmibm
d92c80b560 just swap BaseRepo implementation 2020-07-23 11:58:22 -05:00
vilmibm
2a99ed9afb add ResolvedBaseRepo 2020-07-23 11:01:29 -05:00
vilmibm
a27c8a9c21 isolate repo view cmd 2020-07-22 15:54:11 -05:00
vilmibm
c06eacf4ee remove obsolete ensureScopes 2020-07-21 17:42:52 -05:00
Mislav Marohnić
e373195817 WIP migrate gist create to separate package 2020-07-21 18:13:16 +02:00
Mislav Marohnić
9e4af479da Add command line docs for supported environment variables 2020-07-16 17:46:09 +02:00
Nate Smith
619ef43f76
Merge pull request #1191 from cli/shell-alias
shell aliases
2020-07-15 12:24:36 -05:00
vilmibm
86912b31b2 stub sh lookup 2020-07-15 12:17:36 -05:00
vilmibm
cfb8eebf30 quietly return exit code of external command 2020-07-15 11:39:48 -05:00
vilmibm
acaaa28fd7 helper function for finding sh 2020-07-15 11:30:20 -05:00
Mislav Marohnić
c8cf54c10c
Merge pull request #1258 from cli/ghe-remotes
Parse and respect non-github.com git remotes
2020-07-15 13:07:30 +02:00
nate smith
4bd0435c38 successfully use sh for windows aliases 2020-07-14 16:19:01 -05:00
vilmibm
f99b54a731 WIP: experimental bash support for windows 2020-07-14 16:13:00 -05:00
vilmibm
bbd756a99f split shell alias execution into new function 2020-07-14 16:13:00 -05:00
nate smith
c3a5384895 add experimental powershell support for shell aliases 2020-07-14 16:12:51 -05:00
vilmibm
3a9167cfe4 Implement shell aliases
This command adds --shell to `gh alias set`, allowing specified aliases
to be run through a shell interpreter.
2020-07-14 16:12:07 -05:00
vilmibm
36ade42ba3 scriptability improvements: issue commands
This commit is part of work to make gh more scriptable. It includes both
some general purpose helpers towards this goal as well as improvements
to the issue commands. Other commands will follow.

- Adds `utils/terminal.go` for finding out about gh's execution environment
- introduces `stubTerminal` for either faking being attached to a tty or not during tests
- updates issue commands to behave better when not attached to a tty:
  - issue list doesn't print fuzzy dates
  - issue list doesn't print header
  - issue list prints state explicitly
  - issue create no longer hangs
  - issue create fails with clear error unless both -t and -b are specified
  - issue view prints raw issue body
  - issue view prints metadata in a consistent, linewise format
2020-07-14 12:30:53 -05:00