openclaw-openviking-setup-helper 0.3.0-beta.6 → 0.3.0-beta.7

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/install.js +7 -1
  2. package/package.json +1 -1
package/install.js CHANGED
@@ -1418,9 +1418,11 @@ async function configureOpenClawPlugin({
1418
1418
  const pluginSlot = resolvedPluginSlot;
1419
1419
 
1420
1420
  const ocEnv = getOpenClawEnv();
1421
+ const needWorkdirFlag = OPENCLAW_DIR !== DEFAULT_OPENCLAW_DIR;
1421
1422
 
1422
1423
  const oc = async (args) => {
1423
- const result = await runCapture("openclaw", args, { env: ocEnv, shell: IS_WIN });
1424
+ const fullArgs = needWorkdirFlag ? [...args, "--workdir", OPENCLAW_DIR] : args;
1425
+ const result = await runCapture("openclaw", fullArgs, { env: ocEnv, shell: IS_WIN });
1424
1426
  if (result.code !== 0) {
1425
1427
  const detail = result.err || result.out;
1426
1428
  throw new Error(`openclaw ${args.join(" ")} failed (exit code ${result.code})${detail ? `: ${detail}` : ""}`);
@@ -1502,6 +1504,10 @@ async function configureOpenClawPlugin({
1502
1504
  setupArgs.push("--allow-offline");
1503
1505
  }
1504
1506
 
1507
+ if (needWorkdirFlag) {
1508
+ setupArgs.push("--workdir", OPENCLAW_DIR);
1509
+ }
1510
+
1505
1511
  info(tr(
1506
1512
  "Delegating configuration to: openclaw openviking setup --json",
1507
1513
  "委托配置给: openclaw openviking setup --json",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "openclaw-openviking-setup-helper",
3
- "version": "0.3.0-beta.6",
3
+ "version": "0.3.0-beta.7",
4
4
  "description": "Setup helper for installing OpenViking memory plugin into OpenClaw",
5
5
  "type": "module",
6
6
  "bin": {