@gorlitzer-labs/seldon 0.1.18 → 0.1.19

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/seldon.js +4 -2
  2. package/package.json +4 -1
package/bin/seldon.js CHANGED
@@ -317,8 +317,10 @@ async function doUninstall(ids, { yes = false, all = false } = {}) {
317
317
  // The stack's only always-on services are the voice (demerzel) and the
318
318
  // supervisor loop (factory watch). We run them as detached background daemons,
319
319
  // track them by pidfile under ~/.seldon/run, and print one map of where to go.
320
- const RUN_DIR = path.join(process.env.HOME, ".seldon", "run");
321
- const SELDON_HOME = path.join(process.env.HOME, ".seldon");
320
+ // SELDON_HOME can be overridden (tests point it at a temp dir; also a legit
321
+ // user override). Everything — run/, bonsai/, demerzel/, brain — derives from it.
322
+ const SELDON_HOME = process.env.SELDON_HOME || path.join(process.env.HOME, ".seldon");
323
+ const RUN_DIR = path.join(SELDON_HOME, "run");
322
324
  const pidFile = (name) => path.join(RUN_DIR, name + ".pid");
323
325
  const readPid = (name) => { try { return parseInt(fs.readFileSync(pidFile(name), "utf8").trim(), 10) || 0; } catch { return 0; } };
324
326
  const isAlive = (pid) => { try { process.kill(pid, 0); return true; } catch { return false; } };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gorlitzer-labs/seldon",
3
- "version": "0.1.18",
3
+ "version": "0.1.19",
4
4
  "description": "Install the Seldon stack — pick your tools from a checklist; each installs via its native method.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -27,5 +27,8 @@
27
27
  "license": "MIT",
28
28
  "publishConfig": {
29
29
  "access": "public"
30
+ },
31
+ "scripts": {
32
+ "test": "node --test test/*.test.mjs"
30
33
  }
31
34
  }