synabun 2026.4.26-beta.15 → 2026.4.26-beta.16
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/neural-interface/server.js +14 -5
- package/package.json +1 -1
|
@@ -2556,9 +2556,14 @@ function getClaudeBin() {
|
|
|
2556
2556
|
// Might be a bare command in PATH — try which/where
|
|
2557
2557
|
try {
|
|
2558
2558
|
const envWithPath = { ...process.env, PATH: getAugmentedPath() };
|
|
2559
|
-
|
|
2560
|
-
|
|
2561
|
-
|
|
2559
|
+
let lookup;
|
|
2560
|
+
if (process.platform === 'win32') {
|
|
2561
|
+
const lines = execSync(`where "${userCmd}"`, { encoding: 'utf-8', env: envWithPath })
|
|
2562
|
+
.split(/\r?\n/).map(l => l.trim()).filter(Boolean);
|
|
2563
|
+
lookup = lines.find(l => /\.(cmd|exe|bat|ps1)$/i.test(l)) || lines[0];
|
|
2564
|
+
} else {
|
|
2565
|
+
lookup = execSync(`which "${userCmd}"`, { encoding: 'utf-8', env: envWithPath }).trim();
|
|
2566
|
+
}
|
|
2562
2567
|
if (lookup) { _claudeBinPath = lookup; return _claudeBinPath; }
|
|
2563
2568
|
} catch {}
|
|
2564
2569
|
}
|
|
@@ -2596,8 +2601,12 @@ function getClaudeBin() {
|
|
|
2596
2601
|
// 2. Fall back to global install via which/where (with augmented PATH)
|
|
2597
2602
|
const envWithPath = { ...process.env, PATH: getAugmentedPath() };
|
|
2598
2603
|
if (process.platform === 'win32') {
|
|
2599
|
-
try {
|
|
2600
|
-
|
|
2604
|
+
try {
|
|
2605
|
+
const lines = execSync('where claude', { encoding: 'utf-8', env: envWithPath })
|
|
2606
|
+
.split(/\r?\n/).map(l => l.trim()).filter(Boolean);
|
|
2607
|
+
// Prefer .cmd/.exe/.bat/.ps1 over the bare extensionless shim (which is a sh script Windows can't spawn)
|
|
2608
|
+
_claudeBinPath = lines.find(l => /\.(cmd|exe|bat|ps1)$/i.test(l)) || lines[0] || null;
|
|
2609
|
+
} catch { _claudeBinPath = null; }
|
|
2601
2610
|
} else {
|
|
2602
2611
|
try { _claudeBinPath = execSync('which claude', { encoding: 'utf-8', env: envWithPath }).trim(); }
|
|
2603
2612
|
catch { _claudeBinPath = null; }
|