MCPcopy Create free account
hub / github.com/cli/cli / IsStdinTTY

Method IsStdinTTY

pkg/iostreams/iostreams.go:167–175  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

165}
166
167func (s *IOStreams) IsStdinTTY() bool {
168 if s.stdinTTYOverride {
169 return s.stdinIsTTY
170 }
171 if stdin, ok := s.In.(*os.File); ok {
172 return isTerminal(stdin)
173 }
174 return false
175}
176
177func (s *IOStreams) SetStdoutTTY(isTTY bool) {
178 s.stdoutTTYOverride = true

Callers 8

CanPromptMethod · 0.95
NewCmdAddFunction · 0.80
NewCmdImportFunction · 0.80
NewCmdCreateFunction · 0.80
forkRunFunction · 0.80
NewCmdAddFunction · 0.80
previewPRFunction · 0.80
NewCmdRunFunction · 0.80

Calls 1

isTerminalFunction · 0.85

Tested by

no test coverage detected