codeam-cli 1.0.3 → 1.0.4
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.
- package/dist/index.js +9 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -476,17 +476,23 @@ var ClaudeService = class {
|
|
|
476
476
|
process.exit(1);
|
|
477
477
|
}
|
|
478
478
|
const claudeCmd = findInPath("claude") ? "claude" : "claude-code";
|
|
479
|
+
const shell = process.env.SHELL || "/bin/sh";
|
|
479
480
|
try {
|
|
480
|
-
this.proc = pty.spawn(
|
|
481
|
+
this.proc = pty.spawn(shell, ["-c", `exec ${claudeCmd}`], {
|
|
481
482
|
name: "xterm-256color",
|
|
482
483
|
cols: process.stdout.columns || 80,
|
|
483
484
|
rows: process.stdout.rows || 24,
|
|
484
485
|
cwd: this.opts.cwd,
|
|
485
486
|
env: process.env
|
|
486
487
|
});
|
|
487
|
-
} catch {
|
|
488
|
+
} catch (err) {
|
|
489
|
+
const msg = err instanceof Error ? err.message : String(err);
|
|
488
490
|
console.error(
|
|
489
|
-
|
|
491
|
+
`
|
|
492
|
+
\u2717 Failed to launch Claude Code: ${msg}
|
|
493
|
+
Make sure claude is correctly installed: npm install -g @anthropic-ai/claude-code
|
|
494
|
+
If the issue persists, try: npm rebuild node-pty
|
|
495
|
+
`
|
|
490
496
|
);
|
|
491
497
|
process.exit(1);
|
|
492
498
|
}
|