@wipcomputer/wip-ldm-os 0.4.34 → 0.4.35

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/SKILL.md CHANGED
@@ -5,7 +5,7 @@ license: MIT
5
5
  interface: [cli, skill]
6
6
  metadata:
7
7
  display-name: "LDM OS"
8
- version: "0.4.34"
8
+ version: "0.4.35"
9
9
  homepage: "https://github.com/wipcomputer/wip-ldm-os"
10
10
  author: "Parker Todd Brooks"
11
11
  category: infrastructure
package/lib/deploy.mjs CHANGED
@@ -706,7 +706,7 @@ export function installSingleTool(toolPath) {
706
706
  mkdirSync(trashDir, { recursive: true });
707
707
  const trashDest = join(trashDir, ghostName);
708
708
  cpSync(ghostPath, trashDest, { recursive: true });
709
- execSync(`rm -rf "${ghostPath}"`, { stdio: 'pipe' });
709
+ rmSync(ghostPath, { recursive: true, force: true });
710
710
  // Clean registry
711
711
  const registry = loadRegistry();
712
712
  if (registry.extensions?.[ghostName]) {
@@ -932,7 +932,7 @@ function removeSkill(name) {
932
932
  const skillDir = join(OC_ROOT, 'skills', name);
933
933
  try {
934
934
  if (existsSync(skillDir)) {
935
- execSync(`rm -rf "${skillDir}"`, { stdio: 'pipe' });
935
+ rmSync(skillDir, { recursive: true, force: true });
936
936
  }
937
937
  } catch {}
938
938
  }
package/lib/log.mjs ADDED
@@ -0,0 +1,15 @@
1
+ /**
2
+ * lib/log.mjs
3
+ * Lightweight debug logger for LDM OS.
4
+ * Opt-in via LDM_DEBUG=1 environment variable.
5
+ */
6
+
7
+ const DEBUG = process.env.LDM_DEBUG === '1';
8
+
9
+ export function debug(context, msg, err) {
10
+ if (DEBUG) {
11
+ const ts = new Date().toISOString().slice(11, 19);
12
+ const errMsg = err?.message || '';
13
+ console.error(`[ldm:${context}] ${ts} ${msg}${errMsg ? ' ... ' + errMsg : ''}`);
14
+ }
15
+ }
package/package.json CHANGED
@@ -1,8 +1,11 @@
1
1
  {
2
2
  "name": "@wipcomputer/wip-ldm-os",
3
- "version": "0.4.34",
3
+ "version": "0.4.35",
4
4
  "type": "module",
5
5
  "description": "LDM OS: identity, memory, and sovereignty infrastructure for AI agents",
6
+ "engines": {
7
+ "node": ">=18"
8
+ },
6
9
  "main": "src/boot/boot-hook.mjs",
7
10
  "bin": {
8
11
  "ldm": "bin/ldm.js",
@@ -4,13 +4,14 @@
4
4
  import { execSync, exec } from "node:child_process";
5
5
  import { readdirSync, readFileSync, existsSync, statSync } from "node:fs";
6
6
  import { join, relative, resolve } from "node:path";
7
+ import { homedir } from "node:os";
7
8
  import { promisify } from "node:util";
8
9
 
9
10
  const execAsync = promisify(exec);
10
11
 
11
12
  // ── Constants ─────────────────────────────────────────────────────────
12
13
 
13
- const HOME = process.env.HOME || "/Users/lesa";
14
+ const HOME = process.env.HOME || homedir();
14
15
  export const LDM_ROOT = process.env.LDM_ROOT || join(HOME, ".ldm");
15
16
 
16
17
  // ── Types ────────────────────────────────────────────────────────────