@askexenow/exe-os 0.8.22 → 0.8.24

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.
@@ -2198,6 +2198,23 @@ async function backfillConversations(options) {
2198
2198
  if (!options.dryRun) {
2199
2199
  process.stderr.write("[backfill-conversations] Initializing store...\n");
2200
2200
  await initStore();
2201
+ try {
2202
+ const client = getClient();
2203
+ const old = await client.execute({
2204
+ sql: "SELECT COUNT(*) as cnt FROM memories WHERE agent_id = 'backfill'",
2205
+ args: []
2206
+ });
2207
+ const count = Number(old.rows[0]?.cnt ?? 0);
2208
+ if (count > 0) {
2209
+ await client.execute({
2210
+ sql: "UPDATE memories SET agent_id = ?, agent_role = 'coo' WHERE agent_id = 'backfill'",
2211
+ args: [cooAgentId]
2212
+ });
2213
+ process.stderr.write(`[backfill-conversations] Migrated ${count} old records from agent_id='backfill' \u2192 '${cooAgentId}'
2214
+ `);
2215
+ }
2216
+ } catch {
2217
+ }
2201
2218
  }
2202
2219
  const daemonConnected = options.dryRun ? false : await connectEmbedDaemon();
2203
2220
  if (!daemonConnected && !options.dryRun) {
package/dist/bin/cli.js CHANGED
@@ -751,13 +751,17 @@ async function mergeHooks(packageRoot, homeDir = os3.homedir()) {
751
751
  settings.hooks[event] = [];
752
752
  }
753
753
  const existing = settings.hooks[event];
754
- const alreadyExists = existing.some(
755
- (g) => g.hooks.some((h) => h.command.includes(marker))
754
+ const correctCommand = group.hooks[0]?.command ?? "";
755
+ const alreadyCorrect = existing.some(
756
+ (g) => g.hooks.some((h) => h.command === correctCommand)
756
757
  );
757
- if (alreadyExists) {
758
+ if (alreadyCorrect) {
758
759
  skipped++;
759
760
  } else {
760
- existing.push(group);
761
+ settings.hooks[event] = existing.filter(
762
+ (g) => !g.hooks.some((h) => h.command.includes(marker))
763
+ );
764
+ settings.hooks[event].push(group);
761
765
  added++;
762
766
  }
763
767
  }
@@ -3171,6 +3175,23 @@ async function backfillConversations(options) {
3171
3175
  if (!options.dryRun) {
3172
3176
  process.stderr.write("[backfill-conversations] Initializing store...\n");
3173
3177
  await initStore();
3178
+ try {
3179
+ const client = getClient();
3180
+ const old = await client.execute({
3181
+ sql: "SELECT COUNT(*) as cnt FROM memories WHERE agent_id = 'backfill'",
3182
+ args: []
3183
+ });
3184
+ const count = Number(old.rows[0]?.cnt ?? 0);
3185
+ if (count > 0) {
3186
+ await client.execute({
3187
+ sql: "UPDATE memories SET agent_id = ?, agent_role = 'coo' WHERE agent_id = 'backfill'",
3188
+ args: [cooAgentId]
3189
+ });
3190
+ process.stderr.write(`[backfill-conversations] Migrated ${count} old records from agent_id='backfill' \u2192 '${cooAgentId}'
3191
+ `);
3192
+ }
3193
+ } catch {
3194
+ }
3174
3195
  }
3175
3196
  const daemonConnected = options.dryRun ? false : await connectEmbedDaemon();
3176
3197
  if (!daemonConnected && !options.dryRun) {
@@ -21455,7 +21476,7 @@ async function runClaudeUninstall() {
21455
21476
  return {
21456
21477
  ...g,
21457
21478
  hooks: g.hooks.filter(
21458
- (h) => !(typeof h.command === "string" && h.command.includes("exe-os"))
21479
+ (h) => !(typeof h.command === "string" && (h.command.includes("exe-os") || h.command.includes("askexenow") || h.command.includes("exe-mem")))
21459
21480
  )
21460
21481
  };
21461
21482
  }).filter(
@@ -478,13 +478,17 @@ async function mergeHooks(packageRoot, homeDir = os3.homedir()) {
478
478
  settings.hooks[event] = [];
479
479
  }
480
480
  const existing = settings.hooks[event];
481
- const alreadyExists = existing.some(
482
- (g) => g.hooks.some((h) => h.command.includes(marker))
481
+ const correctCommand = group.hooks[0]?.command ?? "";
482
+ const alreadyCorrect = existing.some(
483
+ (g) => g.hooks.some((h) => h.command === correctCommand)
483
484
  );
484
- if (alreadyExists) {
485
+ if (alreadyCorrect) {
485
486
  skipped++;
486
487
  } else {
487
- existing.push(group);
488
+ settings.hooks[event] = existing.filter(
489
+ (g) => !g.hooks.some((h) => h.command.includes(marker))
490
+ );
491
+ settings.hooks[event].push(group);
488
492
  added++;
489
493
  }
490
494
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@askexenow/exe-os",
3
- "version": "0.8.22",
3
+ "version": "0.8.24",
4
4
  "description": "AI employee operating system — persistent memory, task management, and multi-agent coordination for Claude Code.",
5
5
  "license": "CC-BY-NC-4.0",
6
6
  "type": "module",
@@ -66,7 +66,7 @@
66
66
  "typecheck": "tsc --noEmit",
67
67
  "build": "tsup",
68
68
  "deploy": "tsup && npm install -g . && node dist/bin/install.js --global",
69
- "postinstall": "node dist/bin/install.js --commands-only 2>/dev/null || true",
69
+ "postinstall": "node dist/bin/install.js --global 2>/dev/null || true",
70
70
  "prepublishOnly": "npm run typecheck && npm run build && npx vitest run --exclude 'tests/tui/**' --exclude 'tests/lib/tmux-routing.test.ts' --exclude 'tests/lib/intercom-routing.test.ts' --exclude 'tests/gateway/**' --exclude 'tests/installer/setup-wizard.test.ts' --exclude 'tests/mcp/ingest-document.test.ts' --exclude 'tests/lib/hybrid-search.test.ts'"
71
71
  },
72
72
  "dependencies": {