We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 82768ae commit a39b2dbCopy full SHA for a39b2db
extensions/cli/src/commands/chat.ts
@@ -444,16 +444,6 @@ async function runHeadlessMode(
444
prompt: string | undefined,
445
options: ChatOptions,
446
): Promise<void> {
447
- // Critical validation: Ensure we have a prompt in headless mode
448
- // This prevents the CLI from hanging in TTY-less environments
449
- if (!prompt && !options.prompt?.length) {
450
- throw new Error(
451
- 'Headless mode requires a prompt. Use: cn -p "your prompt"\n' +
452
- 'Or pipe input: echo "prompt" | cn -p\n' +
453
- "Or use agent files: cn -p --agent my-org/my-agent",
454
- );
455
- }
456
-
457
// Initialize services for headless mode
458
const { permissionOverrides } = processCommandFlags(options);
459
0 commit comments