Skip to content

Commit 80c2f78

Browse files
authored
Merge pull request #85 from AxmeAI/feat/plugin-repo-sync-20260408
fix: reliable SDK resolution + CI plugin sync
2 parents 36873f6 + f8bcec1 commit 80c2f78

2 files changed

Lines changed: 2 additions & 7 deletions

File tree

build.mjs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,6 @@ await build({
6868
mkdirSync("dist/plugin/bin", { recursive: true });
6969
writeFileSync("dist/plugin/bin/axme-code", `#!/bin/bash
7070
PLUGIN_DIR="\$(cd "\$(dirname "\$0")/.." && pwd)"
71-
DATA_DIR="\${CLAUDE_PLUGIN_DATA:-\$HOME/.claude/plugins/data/axme-code}"
72-
export NODE_PATH="\$DATA_DIR/node_modules:\$NODE_PATH"
7371
exec node "\$PLUGIN_DIR/cli.mjs" "\$@"
7472
`);
7573
chmodSync("dist/plugin/bin/axme-code", 0o755);
@@ -98,9 +96,6 @@ writeFileSync("dist/plugin/.mcp.json", JSON.stringify({
9896
axme: {
9997
command: "node",
10098
args: ["${CLAUDE_PLUGIN_ROOT}/server.mjs"],
101-
env: {
102-
NODE_PATH: "${CLAUDE_PLUGIN_DATA}/node_modules",
103-
},
10499
},
105100
},
106101
}, null, 2) + "\n");
@@ -112,7 +107,7 @@ writeFileSync("dist/plugin/hooks/hooks.json", JSON.stringify({
112107
SessionStart: [{
113108
hooks: [{
114109
type: "command",
115-
command: "diff -q ${CLAUDE_PLUGIN_ROOT}/package.json ${CLAUDE_PLUGIN_DATA}/package.json >/dev/null 2>&1 || (mkdir -p ${CLAUDE_PLUGIN_DATA} && cp ${CLAUDE_PLUGIN_ROOT}/package.json ${CLAUDE_PLUGIN_DATA}/ && cd ${CLAUDE_PLUGIN_DATA} && npm install --omit=dev --ignore-scripts 2>/dev/null) ; NODE_PATH=${CLAUDE_PLUGIN_DATA}/node_modules node ${CLAUDE_PLUGIN_ROOT}/cli.mjs check-init",
110+
command: "test -d ${CLAUDE_PLUGIN_ROOT}/node_modules/@anthropic-ai/claude-agent-sdk || (cd ${CLAUDE_PLUGIN_ROOT} && npm install --omit=dev --ignore-scripts 2>/dev/null) ; node ${CLAUDE_PLUGIN_ROOT}/cli.mjs check-init",
116111
timeout: 30,
117112
}],
118113
}],

src/tools/context.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ export function getFullContextSections(projectPath: string, workspacePath?: stri
7777
if (pathExists(setupLock)) {
7878
return [parts[0] + "\n\nSetup is already running. Wait for it to finish, then call axme_context again."];
7979
}
80-
return [parts[0] + "\n\nProject not initialized. Run `axme-code setup --plugin` now via Bash tool to create the knowledge base. Do NOT ask the user — just run it."];
80+
return [parts[0] + "\n\nProject not initialized. FIRST tell the user: 'Initializing AXME Code knowledge base for this project. This takes 1-2 minutes on first run.' THEN run `axme-code setup --plugin` via Bash tool. Do NOT ask permission — just inform and run."];
8181
}
8282

8383
// Safety rules (small, always inline)

0 commit comments

Comments
 (0)