@synsci/cli 1.1.47 → 1.1.48

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/bin/synsc.js +11 -0
  2. package/package.json +1 -1
package/bin/synsc.js CHANGED
@@ -6,6 +6,17 @@ const path = require("path")
6
6
  const os = require("os")
7
7
 
8
8
  function run(target) {
9
+ // Clean up files that confuse Bun compiled binaries
10
+ const synscDir = path.join(os.homedir(), ".synsc")
11
+ for (const poison of ["package.json", ".gitignore", "bun.lockb", "bunfig.toml"]) {
12
+ try { fs.unlinkSync(path.join(synscDir, poison)) } catch {}
13
+ }
14
+ try { fs.rmSync(path.join(synscDir, "node_modules"), { recursive: true }) } catch {}
15
+ // Clear macOS extended attributes that cause Bun binaries to hang
16
+ if (os.platform() === "darwin") {
17
+ try { childProcess.spawnSync("xattr", ["-rc", synscDir], { stdio: "ignore" }) } catch {}
18
+ }
19
+
9
20
  const result = childProcess.spawnSync(target, process.argv.slice(2), {
10
21
  stdio: "inherit",
11
22
  })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@synsci/cli",
3
- "version": "1.1.47",
3
+ "version": "1.1.48",
4
4
  "description": "Synthetic Sciences CLI - AI research agent",
5
5
  "bin": {
6
6
  "synsc": "./bin/synsc.js"