claudeboard 2.1.0 → 2.2.0
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/agents/developer.js +34 -3
- package/package.json +1 -1
package/agents/developer.js
CHANGED
|
@@ -39,6 +39,39 @@ function resolveClaudePath() {
|
|
|
39
39
|
|
|
40
40
|
const CLAUDE_PATH = resolveClaudePath();
|
|
41
41
|
|
|
42
|
+
// Build a full PATH for the Claude Code subprocess
|
|
43
|
+
// Exit code 127 = "command not found" inside the subprocess — node/npm not in PATH
|
|
44
|
+
function buildEnv() {// Exit code 127 = "command not found" inside the subprocess — node/npm not in PATH
|
|
45
|
+
function buildEnv() {
|
|
46
|
+
// Get node/npm directory to ensure they're in PATH
|
|
47
|
+
let nodeBinDir = "";
|
|
48
|
+
try {
|
|
49
|
+
nodeBinDir = execSync("dirname $(which node)", { stdio: "pipe" }).toString().trim();
|
|
50
|
+
} catch {}
|
|
51
|
+
|
|
52
|
+
// Merge: existing PATH + node bin dir + common locations
|
|
53
|
+
const pathParts = [
|
|
54
|
+
process.env.PATH || "",
|
|
55
|
+
nodeBinDir,
|
|
56
|
+
"/opt/homebrew/bin",
|
|
57
|
+
"/opt/homebrew/sbin",
|
|
58
|
+
"/usr/local/bin",
|
|
59
|
+
"/usr/bin",
|
|
60
|
+
"/bin",
|
|
61
|
+
`${process.env.HOME}/.npm-global/bin`,
|
|
62
|
+
`${process.env.HOME}/.nvm/versions/node/current/bin`,
|
|
63
|
+
].filter(Boolean);
|
|
64
|
+
|
|
65
|
+
const fullPath = [...new Set(pathParts.join(":").split(":"))].join(":");
|
|
66
|
+
|
|
67
|
+
return {
|
|
68
|
+
...process.env,
|
|
69
|
+
PATH: fullPath,
|
|
70
|
+
ANTHROPIC_API_KEY: process.env.ANTHROPIC_API_KEY,
|
|
71
|
+
HOME: process.env.HOME,
|
|
72
|
+
};
|
|
73
|
+
}
|
|
74
|
+
|
|
42
75
|
// Tools Claude Code can use — full developer access
|
|
43
76
|
const DEVELOPER_TOOLS = [
|
|
44
77
|
"Read", // Read any file in the project
|
|
@@ -122,9 +155,7 @@ ${retryNote}
|
|
|
122
155
|
preset: "claude_code",
|
|
123
156
|
append: DEV_RULES,
|
|
124
157
|
},
|
|
125
|
-
env:
|
|
126
|
-
ANTHROPIC_API_KEY: process.env.ANTHROPIC_API_KEY,
|
|
127
|
-
},
|
|
158
|
+
env: buildEnv(),
|
|
128
159
|
},
|
|
129
160
|
})) {
|
|
130
161
|
|