@hanzo/dev 0.7.11 → 0.7.13

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/README.md CHANGED
@@ -170,7 +170,8 @@ apply inside it.
170
170
  ## Contributing
171
171
 
172
172
  Branch, make the change, make `./build-fast.sh` pass, open a pull request.
173
- Bugs and feature requests: [github.com/hanzoai/dev/issues](https://github.com/hanzoai/dev/issues).
173
+ Bugs and feature requests: [github.com/hanzoai/cli/issues](https://github.com/hanzoai/cli/issues),
174
+ the tracker for `hanzo` and the `hanzo dev` it runs (this repository has issues turned off).
174
175
 
175
176
  ## License
176
177
 
package/bin/coder.js CHANGED
@@ -397,9 +397,24 @@ const { spawn } = await import("child_process");
397
397
  // Make the resolved native binary path visible to spawned agents/subprocesses.
398
398
  process.env.CODE_BINARY_PATH = binaryPath;
399
399
 
400
+ // Prepend @hanzo/dev's bundled node_modules/.bin (which includes @hanzo/mcp -> hanzo-mcp)
401
+ // and ~/.local/bin to PATH so `dev` always finds `hanzo-mcp` natively.
402
+ const localMcpBin = path.join(__dirname, "..", "node_modules", ".bin");
403
+ const userLocalBin = path.join(os.homedir(), ".local", "bin");
404
+ const extraPaths = [localMcpBin, userLocalBin].filter((dir) => existsSync(dir));
405
+ const mergedPath = extraPaths
406
+ .concat((process.env.PATH || "").split(path.delimiter).filter(Boolean))
407
+ .join(path.delimiter);
408
+
400
409
  const child = spawn(binaryPath, process.argv.slice(2), {
401
410
  stdio: "inherit",
402
- env: { ...process.env, CODER_MANAGED_BY_NPM: "1", DEV_MANAGED_BY_NPM: "1", CODE_BINARY_PATH: binaryPath },
411
+ env: {
412
+ ...process.env,
413
+ PATH: mergedPath,
414
+ CODER_MANAGED_BY_NPM: "1",
415
+ DEV_MANAGED_BY_NPM: "1",
416
+ CODE_BINARY_PATH: binaryPath,
417
+ },
403
418
  });
404
419
 
405
420
  child.on("error", (err) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hanzo/dev",
3
- "version": "0.7.11",
3
+ "version": "0.7.13",
4
4
  "license": "Apache-2.0",
5
5
  "description": "Local AI coding agent for your terminal, powered by Hanzo AI",
6
6
  "bin": {
@@ -37,10 +37,10 @@
37
37
  "prettier": "^3.9.6"
38
38
  },
39
39
  "optionalDependencies": {
40
- "@hanzo/dev-darwin-arm64": "0.7.11",
41
- "@hanzo/dev-darwin-x64": "0.7.11",
42
- "@hanzo/dev-linux-x64-musl": "0.7.11",
43
- "@hanzo/dev-linux-arm64-musl": "0.7.11",
44
- "@hanzo/dev-win32-x64": "0.7.11"
40
+ "@hanzo/dev-darwin-arm64": "0.7.13",
41
+ "@hanzo/dev-darwin-x64": "0.7.13",
42
+ "@hanzo/dev-linux-x64-musl": "0.7.13",
43
+ "@hanzo/dev-linux-arm64-musl": "0.7.13",
44
+ "@hanzo/dev-win32-x64": "0.7.13"
45
45
  }
46
46
  }
package/postinstall.js CHANGED
@@ -757,6 +757,23 @@ export async function runPostinstall(options = {}) {
757
757
  ensureWrapper('code-tui', '');
758
758
  ensureWrapper('code-exec', 'exec');
759
759
 
760
+ // Also expose hanzo-mcp from bundled @hanzo/mcp dependency when not already in globalBin
761
+ const mcpBinSource = join(__dirname, 'node_modules', '.bin', isWindows ? 'hanzo-mcp.cmd' : 'hanzo-mcp');
762
+ if (globalBin && existsSync(mcpBinSource)) {
763
+ const mcpWrapperPath = join(globalBin, isWindows ? 'hanzo-mcp.cmd' : 'hanzo-mcp');
764
+ if (!existsSync(mcpWrapperPath)) {
765
+ try {
766
+ const content = isWindows
767
+ ? `@echo off\r\n"${mcpBinSource}" %*\r\n`
768
+ : `#!/bin/sh\nexec "${mcpBinSource}" "$@"\n`;
769
+ writeFileSync(mcpWrapperPath, content);
770
+ if (!isWindows) chmodSync(mcpWrapperPath, 0o755);
771
+ console.log("✓ Created 'hanzo-mcp' wrapper -> @hanzo/mcp");
772
+ installedCmds.add('hanzo-mcp');
773
+ } catch {}
774
+ }
775
+ }
776
+
760
777
  if (collision) {
761
778
  console.error('⚠ Detected existing `code` on PATH:');
762
779
  for (const p of conflictPaths) console.error(` - ${p}`);