MCPcopy Create free account
hub / github.com/QodeXcli/QodeX / isInteractiveTTY

Function isInteractiveTTY

src/setup/prompt.ts:278–286  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

276
277/** Detect whether we have an interactive TTY. CI environments / pipes return false. */
278export function isInteractiveTTY(): boolean {
279 if (process.env.QODEX_SKIP_SETUP === '1') return false;
280 if (!process.stdin.isTTY) return false;
281 if (!process.stdout.isTTY) return false;
282 // Common CI env vars
283 if (process.env.CI === 'true' || process.env.CI === '1') return false;
284 if (process.env.GITHUB_ACTIONS) return false;
285 return true;
286}
287
288/** Single-line read from stdin, returning the user's input without the trailing newline. */
289function readLine(promptText: string): Promise<string> {

Callers 3

index.tsFile · 0.85
interactiveAddProviderFunction · 0.85
runSetupFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected