@aegisagentics/agent 0.2.1 → 0.2.2

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/npm/install.js CHANGED
@@ -8,10 +8,12 @@ import { aegisPaths } from "./lib/config.js";
8
8
  import { parseBootstrapCommand } from "./lib/cli.js";
9
9
  import {
10
10
  hookFilesForCodexUninstall,
11
- installAegisHooksFiles,
12
11
  scrubAegisHooksFiles
13
12
  } from "./lib/codex-hooks.js";
14
- import { installCodexPlugin, uninstallCodexPlugin } from "./lib/codex-plugin.js";
13
+ import {
14
+ installCodexPluginAsSingleHookSource,
15
+ uninstallCodexPlugin
16
+ } from "./lib/codex-plugin.js";
15
17
  import {
16
18
  detectCodexHome,
17
19
  prepareCodexPluginInstallTarget
@@ -159,22 +161,22 @@ async function runCodexPluginAction(action, paths, { softFail }) {
159
161
  `Codex marketplace file not found at ${target.marketplaceFile}. Run the Aegis install command first.`
160
162
  );
161
163
  }
162
- const hookInstallResults = await installAegisHooksFiles({
163
- binaryPath: target.binaryFile,
164
- files: hookFilesForCodexUninstall({
164
+ const scrubResults = await installCodexPluginAsSingleHookSource({
165
+ marketplaceFile: target.marketplaceFile,
166
+ legacyHookFiles: hookFilesForCodexUninstall({
165
167
  codexHome: target.codexHome,
166
168
  userPaths: paths
167
169
  })
168
170
  });
169
- const addedHooks = hookInstallResults.reduce((sum, result) => sum + result.added, 0);
170
- const replacedHooks = hookInstallResults.reduce((sum, result) => sum + result.replaced, 0);
171
- await installCodexPlugin({ marketplaceFile: target.marketplaceFile });
171
+ const removedHooks = scrubResults.reduce((sum, result) => sum + result.removed, 0);
172
172
  if (target.mirrored) {
173
173
  console.log(`Prepared Codex-isolated Aegis runtime: ${target.codexHome}`);
174
174
  }
175
- console.log(
176
- `Installed Aegis Codex hooks.json entries: ${addedHooks} added, ${replacedHooks} replaced`
177
- );
175
+ if (removedHooks > 0) {
176
+ console.log(
177
+ `Removed ${removedHooks} legacy Aegis hook entr${removedHooks === 1 ? "y" : "ies"} from Codex hooks.json`
178
+ );
179
+ }
178
180
  console.log("Codex plugin installed: aegis@aegis");
179
181
  return 0;
180
182
  }
@@ -1,6 +1,8 @@
1
1
  import { spawn } from "node:child_process";
2
2
  import path from "node:path";
3
3
 
4
+ import { scrubAegisHooksFiles } from "./codex-hooks.js";
5
+
4
6
  export const DEFAULT_CODEX_PLUGIN_ID = "aegis@aegis";
5
7
  export const DEFAULT_CODEX_PLUGIN_NAME = "aegis";
6
8
 
@@ -55,6 +57,16 @@ export async function installCodexPlugin({
55
57
  });
56
58
  }
57
59
 
60
+ export async function installCodexPluginAsSingleHookSource({
61
+ legacyHookFiles,
62
+ marketplaceFile,
63
+ installPlugin = installCodexPlugin,
64
+ scrubHooks = scrubAegisHooksFiles
65
+ }) {
66
+ await installPlugin({ marketplaceFile });
67
+ return await scrubHooks(legacyHookFiles);
68
+ }
69
+
58
70
  export async function uninstallCodexPlugin({
59
71
  codexCommand = "codex",
60
72
  pluginId = DEFAULT_CODEX_PLUGIN_ID,
@@ -1,23 +1,23 @@
1
1
  {
2
2
  "schemaVersion": "aegis.agent_release_manifest.v1",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "releaseBaseUrl": "https://aegisagentics.com/releases/aegis-agent",
5
- "createdAt": "2026-10-01T09:22:45.760Z",
5
+ "createdAt": "2026-10-01T11:25:46.176Z",
6
6
  "artifacts": {
7
7
  "darwin-arm64": {
8
- "path": "versions/0.2.1/darwin-arm64/aegis-agent.tar.gz",
9
- "sha256": "36a561e524273dc7c08b1388a01d6c5f0f43ffdcff0643ecc876e5194a54a608",
10
- "sizeBytes": 2295321
8
+ "path": "versions/0.2.2/darwin-arm64/aegis-agent.tar.gz",
9
+ "sha256": "ef213b6832ae5d30285f80f14813f8c7967be056469d0f04c49128d02e64d69e",
10
+ "sizeBytes": 2299577
11
11
  },
12
12
  "darwin-x64": {
13
- "path": "versions/0.2.1/darwin-x64/aegis-agent.tar.gz",
14
- "sha256": "76b5bf4ad9bdd7cc036ae52cc4b8a741819c174b56fd39f43d9459ca72cd896a",
15
- "sizeBytes": 2395547
13
+ "path": "versions/0.2.2/darwin-x64/aegis-agent.tar.gz",
14
+ "sha256": "e97dbf98313870ae05a363c1af6b92c400347e864172a6c96e9e6462a7d909ea",
15
+ "sizeBytes": 2395922
16
16
  },
17
17
  "linux-x64": {
18
- "path": "versions/0.2.1/linux-x64/aegis-agent.tar.gz",
19
- "sha256": "8d00dd70e95138263a94209bda17c17537371c3a1b2ec4b0971912fb0d0c4177",
20
- "sizeBytes": 2526674
18
+ "path": "versions/0.2.2/linux-x64/aegis-agent.tar.gz",
19
+ "sha256": "7053709ce3cae3980c50719bad48ab93676fbdf4d05be38039753478ecf1e967",
20
+ "sizeBytes": 2528068
21
21
  }
22
22
  }
23
23
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aegisagentics/agent",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "Aegis Agent local installer and hook runtime for Codex, Claude Code, Cursor, and OpenClaw.",
5
5
  "type": "module",
6
6
  "repository": {