agestra 4.4.2 → 4.5.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/.claude-plugin/marketplace.json +1 -1
- package/.claude-plugin/plugin.json +1 -1
- package/.gemini/commands/agestra/design.toml +16 -0
- package/.gemini/commands/agestra/idea.toml +16 -0
- package/.gemini/commands/agestra/implement.toml +16 -0
- package/.gemini/commands/agestra/review.toml +16 -0
- package/AGENTS.md +36 -0
- package/GEMINI.md +34 -0
- package/README.ja.md +66 -8
- package/README.ko.md +89 -31
- package/README.md +89 -31
- package/README.zh.md +66 -8
- package/agents/agestra-moderator.md +4 -4
- package/agents/agestra-team-lead.md +2 -2
- package/dist/bundle.js +206 -181
- package/package.json +13 -2
- package/scripts/install-host-mcp.mjs +138 -0
- package/scripts/uninstall-host-mcp.mjs +101 -0
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "agestra",
|
|
3
|
-
"version": "4.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "4.5.2",
|
|
4
|
+
"description": "Multi-host AI orchestration toolkit for Claude Code, Codex CLI, and Gemini CLI",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"packageManager": "npm@11.11.0",
|
|
7
7
|
"workspaces": [
|
|
@@ -16,9 +16,14 @@
|
|
|
16
16
|
"dist/sql-wasm.cjs",
|
|
17
17
|
"dist/sql-wasm.wasm",
|
|
18
18
|
".claude-plugin/",
|
|
19
|
+
".gemini/",
|
|
20
|
+
"AGENTS.md",
|
|
21
|
+
"GEMINI.md",
|
|
19
22
|
"agents/",
|
|
20
23
|
"commands/",
|
|
21
24
|
"hooks/",
|
|
25
|
+
"scripts/install-host-mcp.mjs",
|
|
26
|
+
"scripts/uninstall-host-mcp.mjs",
|
|
22
27
|
"skills/"
|
|
23
28
|
],
|
|
24
29
|
"scripts": {
|
|
@@ -31,10 +36,16 @@
|
|
|
31
36
|
"clean": "turbo clean",
|
|
32
37
|
"prebundle": "npm run sync:metadata",
|
|
33
38
|
"bundle": "node scripts/bundle.mjs",
|
|
39
|
+
"install:codex": "node scripts/install-host-mcp.mjs codex",
|
|
40
|
+
"install:gemini": "node scripts/install-host-mcp.mjs gemini",
|
|
41
|
+
"uninstall:codex": "node scripts/uninstall-host-mcp.mjs codex",
|
|
42
|
+
"uninstall:gemini": "node scripts/uninstall-host-mcp.mjs gemini",
|
|
34
43
|
"prepublishOnly": "npm run build && npm run bundle"
|
|
35
44
|
},
|
|
36
45
|
"keywords": [
|
|
37
46
|
"claude-code-plugin",
|
|
47
|
+
"codex-cli",
|
|
48
|
+
"gemini-cli",
|
|
38
49
|
"mcp",
|
|
39
50
|
"multi-ai",
|
|
40
51
|
"ollama",
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
import fs from "node:fs";
|
|
4
|
+
import path from "node:path";
|
|
5
|
+
import { spawnSync } from "node:child_process";
|
|
6
|
+
import { fileURLToPath } from "node:url";
|
|
7
|
+
|
|
8
|
+
const USAGE = `Usage: node scripts/install-host-mcp.mjs <codex|gemini|all> [--scope project|user] [--trust]
|
|
9
|
+
|
|
10
|
+
Registers the local Agestra MCP bundle with the selected host CLI.
|
|
11
|
+
`;
|
|
12
|
+
|
|
13
|
+
function fail(message) {
|
|
14
|
+
console.error(message);
|
|
15
|
+
process.exit(1);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
function parseArgs(argv) {
|
|
19
|
+
if (argv.includes("--help") || argv.includes("-h")) {
|
|
20
|
+
console.log(USAGE);
|
|
21
|
+
process.exit(0);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
const args = [...argv];
|
|
25
|
+
const target = args.shift();
|
|
26
|
+
let scope = "project";
|
|
27
|
+
let trust = false;
|
|
28
|
+
|
|
29
|
+
while (args.length > 0) {
|
|
30
|
+
const current = args.shift();
|
|
31
|
+
if (current === "--trust") {
|
|
32
|
+
trust = true;
|
|
33
|
+
continue;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
if (current === "--scope") {
|
|
37
|
+
const value = args.shift();
|
|
38
|
+
if (value !== "project" && value !== "user") {
|
|
39
|
+
fail("`--scope` must be `project` or `user`.");
|
|
40
|
+
}
|
|
41
|
+
scope = value;
|
|
42
|
+
continue;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
fail(`Unknown argument: ${current}`);
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
if (!target || !["codex", "gemini", "all"].includes(target)) {
|
|
49
|
+
fail(USAGE);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
return { target, scope, trust };
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
function runCommand(command, args, options = {}) {
|
|
56
|
+
const result = spawnSync(command, args, {
|
|
57
|
+
stdio: "inherit",
|
|
58
|
+
shell: false,
|
|
59
|
+
...options,
|
|
60
|
+
});
|
|
61
|
+
|
|
62
|
+
if (result.error) {
|
|
63
|
+
fail(`Failed to run \`${command}\`: ${result.error.message}`);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
if (typeof result.status === "number" && result.status !== 0) {
|
|
67
|
+
fail(`\`${command} ${args.join(" ")}\` exited with status ${result.status}.`);
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
function commandSucceeds(command, args) {
|
|
72
|
+
const result = spawnSync(command, args, {
|
|
73
|
+
stdio: "ignore",
|
|
74
|
+
shell: false,
|
|
75
|
+
});
|
|
76
|
+
|
|
77
|
+
if (result.error) {
|
|
78
|
+
return false;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
return result.status === 0;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
function resolveBundlePath() {
|
|
85
|
+
const rootDir = path.resolve(path.dirname(fileURLToPath(import.meta.url)), "..");
|
|
86
|
+
const bundlePath = path.join(rootDir, "dist", "bundle.js");
|
|
87
|
+
|
|
88
|
+
if (!fs.existsSync(bundlePath)) {
|
|
89
|
+
fail(`Could not find ${bundlePath}. Run \`npm run bundle\` first.`);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
return bundlePath;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
function installCodex(bundlePath) {
|
|
96
|
+
if (commandSucceeds("codex", ["mcp", "get", "agestra", "--json"])) {
|
|
97
|
+
runCommand("codex", ["mcp", "remove", "agestra"]);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
runCommand("codex", ["mcp", "add", "agestra", "--", process.execPath, bundlePath]);
|
|
101
|
+
console.log("Agestra is now registered with Codex. Open this repo and Codex will pick up AGENTS.md automatically.");
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
function installGemini(bundlePath, scope, trust) {
|
|
105
|
+
if (commandSucceeds("gemini", ["mcp", "remove", "agestra", "--scope", scope])) {
|
|
106
|
+
console.log(`Removed existing Gemini MCP registration for scope \`${scope}\`.`);
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
const args = [
|
|
110
|
+
"mcp",
|
|
111
|
+
"add",
|
|
112
|
+
"agestra",
|
|
113
|
+
process.execPath,
|
|
114
|
+
bundlePath,
|
|
115
|
+
"--scope",
|
|
116
|
+
scope,
|
|
117
|
+
"--description",
|
|
118
|
+
"Agestra multi-AI orchestration MCP server",
|
|
119
|
+
];
|
|
120
|
+
|
|
121
|
+
if (trust) {
|
|
122
|
+
args.push("--trust");
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
runCommand("gemini", args);
|
|
126
|
+
console.log("Agestra is now registered with Gemini. Open this repo and Gemini will load GEMINI.md plus /agestra:* project commands.");
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
const { target, scope, trust } = parseArgs(process.argv.slice(2));
|
|
130
|
+
const bundlePath = resolveBundlePath();
|
|
131
|
+
|
|
132
|
+
if (target === "codex" || target === "all") {
|
|
133
|
+
installCodex(bundlePath);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
if (target === "gemini" || target === "all") {
|
|
137
|
+
installGemini(bundlePath, scope, trust);
|
|
138
|
+
}
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
import { spawnSync } from "node:child_process";
|
|
4
|
+
|
|
5
|
+
const USAGE = `Usage: node scripts/uninstall-host-mcp.mjs <codex|gemini|all> [--scope project|user]
|
|
6
|
+
|
|
7
|
+
Removes the Agestra MCP registration from the selected host CLI.
|
|
8
|
+
`;
|
|
9
|
+
|
|
10
|
+
function fail(message) {
|
|
11
|
+
console.error(message);
|
|
12
|
+
process.exit(1);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
function parseArgs(argv) {
|
|
16
|
+
if (argv.includes("--help") || argv.includes("-h")) {
|
|
17
|
+
console.log(USAGE);
|
|
18
|
+
process.exit(0);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
const args = [...argv];
|
|
22
|
+
const target = args.shift();
|
|
23
|
+
let scope = "project";
|
|
24
|
+
|
|
25
|
+
while (args.length > 0) {
|
|
26
|
+
const current = args.shift();
|
|
27
|
+
if (current === "--scope") {
|
|
28
|
+
const value = args.shift();
|
|
29
|
+
if (value !== "project" && value !== "user") {
|
|
30
|
+
fail("`--scope` must be `project` or `user`.");
|
|
31
|
+
}
|
|
32
|
+
scope = value;
|
|
33
|
+
continue;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
fail(`Unknown argument: ${current}`);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
if (!target || !["codex", "gemini", "all"].includes(target)) {
|
|
40
|
+
fail(USAGE);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
return { target, scope };
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
function runCommand(command, args) {
|
|
47
|
+
const result = spawnSync(command, args, {
|
|
48
|
+
stdio: "inherit",
|
|
49
|
+
shell: false,
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
if (result.error) {
|
|
53
|
+
fail(`Failed to run \`${command}\`: ${result.error.message}`);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
if (typeof result.status === "number" && result.status !== 0) {
|
|
57
|
+
fail(`\`${command} ${args.join(" ")}\` exited with status ${result.status}.`);
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
function commandSucceeds(command, args) {
|
|
62
|
+
const result = spawnSync(command, args, {
|
|
63
|
+
stdio: "ignore",
|
|
64
|
+
shell: false,
|
|
65
|
+
});
|
|
66
|
+
|
|
67
|
+
if (result.error) {
|
|
68
|
+
return false;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
return result.status === 0;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
function uninstallCodex() {
|
|
75
|
+
if (!commandSucceeds("codex", ["mcp", "get", "agestra", "--json"])) {
|
|
76
|
+
console.log("Codex does not have an Agestra MCP registration to remove.");
|
|
77
|
+
return;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
runCommand("codex", ["mcp", "remove", "agestra"]);
|
|
81
|
+
console.log("Removed Agestra from Codex.");
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
function uninstallGemini(scope) {
|
|
85
|
+
if (!commandSucceeds("gemini", ["mcp", "remove", "agestra", "--scope", scope])) {
|
|
86
|
+
console.log(`Gemini does not have an Agestra MCP registration in scope \`${scope}\`.`);
|
|
87
|
+
return;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
console.log(`Removed Agestra from Gemini scope \`${scope}\`.`);
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
const { target, scope } = parseArgs(process.argv.slice(2));
|
|
94
|
+
|
|
95
|
+
if (target === "codex" || target === "all") {
|
|
96
|
+
uninstallCodex();
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
if (target === "gemini" || target === "all") {
|
|
100
|
+
uninstallGemini(scope);
|
|
101
|
+
}
|