snow-flow 4.5.8 → 4.5.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/cli.js +13 -3
  2. package/package.json +1 -1
package/dist/cli.js CHANGED
@@ -555,13 +555,24 @@ async function executeClaudeCode(prompt) {
555
555
  cliLogger.info(`šŸ” Working Directory: ${process.cwd()}`);
556
556
  cliLogger.info(`šŸ” MCP Config: ${mcpConfigPath}`);
557
557
  }
558
- // Start Claude Code process with stdin pipe for prompt, but handle raw mode gracefully
558
+ // Detect if we're in an interactive environment (prevents raw mode errors)
559
+ const isInteractive = process.stdin.isTTY && process.stdout.isTTY && !process.env.CI && !process.env.CODESPACES;
560
+ if (!isInteractive) {
561
+ // Non-interactive environment (Codespaces, CI) - provide manual instructions
562
+ cliLogger.info('āš ļø Non-interactive environment detected (Codespaces/CI)');
563
+ cliLogger.info('šŸ“‹ Manual Claude Code instructions:');
564
+ cliLogger.info('1. Ensure Claude Code is running: ' + chalk_1.default.cyan('claude --dangerously-skip-permissions'));
565
+ cliLogger.info('2. In Claude Code conversation, tell it:');
566
+ cliLogger.info('\n' + chalk_1.default.green(`"${objective}"`));
567
+ cliLogger.info('\nšŸ› ļø All 20+ MCP servers with 235+ Snow-Flow tools are available!');
568
+ return true;
569
+ }
570
+ // Interactive environment - try to start Claude Code
559
571
  const claudeProcess = (0, child_process_1.spawn)('claude', claudeArgs, {
560
572
  stdio: ['pipe', 'inherit', 'inherit'], // pipe stdin to send prompt, inherit stdout/stderr
561
573
  cwd: process.cwd(),
562
574
  env: {
563
575
  ...process.env,
564
- // Prevent raw mode issues in non-interactive environments
565
576
  FORCE_COLOR: '0',
566
577
  NO_COLOR: '1'
567
578
  }
@@ -569,7 +580,6 @@ async function executeClaudeCode(prompt) {
569
580
  // Send the prompt via stdin
570
581
  cliLogger.info('šŸ“ Sending orchestration prompt to Claude Code...');
571
582
  cliLogger.info('šŸš€ Claude Code interface opening with Snow-Flow MCP servers...\n');
572
- cliLogger.info('šŸ› ļø All 20+ MCP servers with 235+ tools are now available!');
573
583
  // Write prompt to stdin
574
584
  if (claudeProcess.stdin) {
575
585
  claudeProcess.stdin.write(prompt);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "snow-flow",
3
- "version": "4.5.8",
3
+ "version": "4.5.9",
4
4
  "description": "Conversational ServiceNow development platform using Claude Code. Multi-agent orchestration with 20+ MCP servers providing 200+ ServiceNow tools for comprehensive platform development.",
5
5
  "main": "dist/index.js",
6
6
  "type": "commonjs",