X Tutup
Skip to content

Commit f7ef503

Browse files
committed
fix: respect GH_FORCE_TTY when running gh pr view
`GH_FORCE_TTY` only affects stdout, not stderr, so this check was failing and the flag was being ignored. I also checked for similar problem in other files but everything else seemed stderr or stdin related. closes cli#5354
1 parent 3a94920 commit f7ef503

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg/cmd/pr/view/view.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ func viewRun(opts *ViewOptions) error {
9898
return err
9999
}
100100

101-
connectedToTerminal := opts.IO.IsStdoutTTY() && opts.IO.IsStderrTTY()
101+
connectedToTerminal := opts.IO.IsStdoutTTY()
102102

103103
if opts.BrowserMode {
104104
openURL := pr.URL

0 commit comments

Comments
 (0)
X Tutup