Martín Montes
cacf0157b3
Using ghinstance.OverridableDefault() instead of a harcoded hostname
2020-09-22 18:22:29 +02:00
Martín Montes
793e866850
Using assert.Regexp for testing stderr's content
2020-09-22 17:50:57 +02:00
Martín Montes
81caade918
Access token tip message using hostname
2020-09-22 12:32:37 +02:00
vilmibm
68a019cc3c
review feedback
2020-09-14 10:16:50 -05:00
vilmibm
2345f49ccb
support auth login --web
2020-09-11 13:07:39 -05:00
vilmibm
3a492b892a
Merge branch 'disable-prompts' of github.com:cli/cli into disable-prompts
2020-09-11 11:42:20 -05:00
vilmibm
1073c97409
review feedback
2020-09-11 11:36:24 -05:00
vilmibm
4d3e26e927
prompts disabled test for auth refresh
...
the behavior for nontty vs. prompts disabled is pretty different so i
opted for a new test, here
2020-09-10 13:19:43 -05:00
vilmibm
c0fc31f7d5
use CanPrompt in commands
2020-09-10 12:13:48 -05:00
vilmibm
15bfb5447b
split auth flow code into new internal package
2020-09-10 12:13:48 -05:00
Mislav Marohnić
c80292c2e8
Extend Config object with GITHUB_TOKEN support
...
Adding GITHUB_TOKEN & GITHUB_ENTERPRISE_TOKEN support orthogonal to
Config was getting out of hand, especially in `auth` commands that
adjust their messaging and error status based on the presence of these
environment variables.
The new approach builds in support for tokens from environment straight
into Config object by composition. Thus, commands need not ever be
concerned with any specific environment variables.
2020-09-07 21:33:26 +02:00
Mislav Marohnić
48a827ee34
Tweak gh config set -h output format on auth login
2020-09-01 13:19:30 +02:00
Mislav Marohnić
0de3f678bc
Only validate --hostname when flag was provided
2020-09-01 13:19:19 +02:00
Mislav Marohnić
b029397d32
Validate the --hostname flag value
2020-09-01 13:06:13 +02:00
Mislav Marohnić
1a051e9c44
Validate hostname as entered in the auth prompt
2020-09-01 12:59:58 +02:00
vilmibm
b08255a720
bonus: GitHub Enterprise Server wording
2020-08-19 10:32:00 -05:00
vilmibm
cba401deb0
check parent annotatiosn for auth skip
2020-08-19 10:21:19 -05:00
vilmibm
850a7ef243
print nice login message when no auth detected
2020-08-18 17:57:52 -05:00
vilmibm
1efd3ebb51
rebase strife
2020-08-12 12:07:36 -05:00
vilmibm
2f1e9ecc7a
review feedback
2020-08-12 12:06:14 -05:00
vilmibm
f7ee39dfeb
bonus: logout error if GITHUB_TOKEN is set
2020-08-12 12:05:56 -05:00
vilmibm
e6ae0a122b
accept additional scopes in auth flow
2020-08-12 12:05:54 -05:00
vilmibm
f1c0d04bc0
gh auth refresh
2020-08-12 12:05:27 -05:00
Mislav Marohnić
aa774c4993
Merge remote-tracking branch 'origin' into issue-commands-isolate
2020-08-12 12:11:01 +02:00
vilmibm
37322ec333
less spacing
2020-08-11 16:45:35 -05:00
vilmibm
6c64cb8d23
remove vestigial return from HasMinimumScopes
2020-08-11 16:33:13 -05:00
vilmibm
36b2d3f6a7
ensure that config is not written
2020-08-11 16:24:08 -05:00
vilmibm
ba2b8d50a1
minor
2020-08-11 16:20:03 -05:00
vilmibm
cd32303404
auth status formatting
2020-08-11 16:16:59 -05:00
vilmibm
3a33735da8
be more helpful
2020-08-11 15:58:00 -05:00
vilmibm
f358e600ac
use SilentError
2020-08-11 15:58:00 -05:00
vilmibm
ec25b735ab
gh auth status
2020-08-11 15:58:00 -05:00
Mislav Marohnić
a6e78d74de
Merge branch 'pr-commands-isolate-3' into issue-commands-isolate
2020-08-11 15:40:05 +02:00
vilmibm
9da7539500
gh auth logout
2020-08-06 12:50:01 -05:00
vilmibm
da33b65d32
remove vestigial httpclient struct member
2020-08-06 12:50:01 -05:00
vilmibm
35f18b6c02
gh auth login
2020-08-06 12:43:35 -05:00