MCPcopy
hub / github.com/cli/cli / IsStdinTTY

Method IsStdinTTY

pkg/iostreams/iostreams.go:155–163  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

153}
154
155func (s *IOStreams) IsStdinTTY() bool {
156 if s.stdinTTYOverride {
157 return s.stdinIsTTY
158 }
159 if stdin, ok := s.In.(*os.File); ok {
160 return isTerminal(stdin)
161 }
162 return false
163}
164
165func (s *IOStreams) SetStdoutTTY(isTTY bool) {
166 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