Skip to content

Commit e31136a

Browse files
committed
docs(auth status): explain --json will always exit with zero
Signed-off-by: Babak K. Shandiz <babakks@github.com>
1 parent 5fddcef commit e31136a

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

pkg/cmd/auth/status/status.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,8 +141,10 @@ func NewCmdStatus(f *cmdutil.Factory, runF func(*StatusOptions) error) *cobra.Co
141141
142142
For each host, the authentication state of each known account is tested and any issues are included in the output.
143143
Each host section will indicate the active account, which will be used when targeting that host.
144+
144145
If an account on any host (or only the one given via %[1]s--hostname%[1]s) has authentication issues,
145-
the command will exit with 1 and output to stderr.
146+
the command will exit with 1 and output to stderr. Note that when using the %[1]s--json%[1]s option, the command
147+
will always exit with zero regardless of any authentication issues, unless there is a fatal error.
146148
147149
To change the active account for a host, see %[1]sgh auth switch%[1]s.
148150
`, "`"),

0 commit comments

Comments
 (0)