@swarmvaultai/cli 0.1.26 → 0.1.28
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/README.md +16 -2
- package/dist/index.js +21 -12
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -255,16 +255,30 @@ Export the current graph as one of four formats:
|
|
|
255
255
|
- `--graphml` for graph-tool interoperability
|
|
256
256
|
- `--cypher` for Neo4j-style import scripts
|
|
257
257
|
|
|
258
|
-
### `swarmvault install --agent <codex|claude|cursor|goose|pi|gemini|opencode>`
|
|
258
|
+
### `swarmvault install --agent <codex|claude|cursor|goose|pi|gemini|opencode|aider|copilot>`
|
|
259
259
|
|
|
260
260
|
Install agent-specific rules into the current project so an agent understands the SwarmVault workspace contract and workflow.
|
|
261
261
|
|
|
262
|
-
|
|
262
|
+
Hook-capable installs:
|
|
263
263
|
|
|
264
264
|
```bash
|
|
265
265
|
swarmvault install --agent claude --hook
|
|
266
|
+
swarmvault install --agent gemini --hook
|
|
267
|
+
swarmvault install --agent opencode --hook
|
|
268
|
+
swarmvault install --agent copilot --hook
|
|
266
269
|
```
|
|
267
270
|
|
|
271
|
+
Agent target mapping:
|
|
272
|
+
|
|
273
|
+
- `codex`, `goose`, `pi`, and `opencode` share `AGENTS.md`
|
|
274
|
+
- `claude` writes `CLAUDE.md`
|
|
275
|
+
- `gemini` writes `GEMINI.md`
|
|
276
|
+
- `aider` writes `CONVENTIONS.md` and merges `.aider.conf.yml`
|
|
277
|
+
- `copilot` writes `.github/copilot-instructions.md` plus `AGENTS.md`
|
|
278
|
+
- `cursor` writes `.cursor/rules/swarmvault.mdc`
|
|
279
|
+
|
|
280
|
+
`aider` is intentionally file/config-based in this release rather than hook-based.
|
|
281
|
+
|
|
268
282
|
## Provider Configuration
|
|
269
283
|
|
|
270
284
|
SwarmVault defaults to a local `heuristic` provider so the CLI works without API keys, but real vaults will usually point at an actual model provider.
|
package/dist/index.js
CHANGED
|
@@ -216,9 +216,9 @@ program.name("swarmvault").description("SwarmVault is a local-first LLM wiki com
|
|
|
216
216
|
function readCliVersion() {
|
|
217
217
|
try {
|
|
218
218
|
const packageJson = JSON.parse(readFileSync(new URL("../package.json", import.meta.url), "utf8"));
|
|
219
|
-
return typeof packageJson.version === "string" && packageJson.version.trim() ? packageJson.version : "0.1.
|
|
219
|
+
return typeof packageJson.version === "string" && packageJson.version.trim() ? packageJson.version : "0.1.28";
|
|
220
220
|
} catch {
|
|
221
|
-
return "0.1.
|
|
221
|
+
return "0.1.28";
|
|
222
222
|
}
|
|
223
223
|
}
|
|
224
224
|
function isJson() {
|
|
@@ -693,17 +693,26 @@ program.command("mcp").description("Run SwarmVault as a local MCP server over st
|
|
|
693
693
|
process2.exit(0);
|
|
694
694
|
});
|
|
695
695
|
});
|
|
696
|
-
program.command("install").description("Install SwarmVault instructions for an agent in the current project.").requiredOption("--agent <agent>", "codex, claude, cursor, goose, pi, gemini, or
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
696
|
+
program.command("install").description("Install SwarmVault instructions for an agent in the current project.").requiredOption("--agent <agent>", "codex, claude, cursor, goose, pi, gemini, opencode, aider, or copilot").option("--hook", "Also install hook/plugin guidance when the target agent supports it", false).action(
|
|
697
|
+
async (options) => {
|
|
698
|
+
const hookCapableAgents = /* @__PURE__ */ new Set(["claude", "opencode", "gemini", "copilot"]);
|
|
699
|
+
if (options.hook && !hookCapableAgents.has(options.agent)) {
|
|
700
|
+
throw new Error("--hook is only supported for --agent claude, opencode, gemini, or copilot");
|
|
701
|
+
}
|
|
702
|
+
const result = await installAgent(process2.cwd(), options.agent, { hook: options.hook ?? false });
|
|
703
|
+
if (isJson()) {
|
|
704
|
+
emitJson({ ...result, hook: options.hook ?? false });
|
|
705
|
+
} else {
|
|
706
|
+
log(`Installed rules into ${result.target}`);
|
|
707
|
+
if (result.targets.length > 1) {
|
|
708
|
+
log(`Also wrote: ${result.targets.filter((entry) => entry !== result.target).join(", ")}`);
|
|
709
|
+
}
|
|
710
|
+
for (const warning of result.warnings ?? []) {
|
|
711
|
+
emitNotice(warning);
|
|
712
|
+
}
|
|
713
|
+
}
|
|
705
714
|
}
|
|
706
|
-
|
|
715
|
+
);
|
|
707
716
|
program.parseAsync(process2.argv).catch((error) => {
|
|
708
717
|
const message = error instanceof Error ? error.message : String(error);
|
|
709
718
|
if (isJson()) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@swarmvaultai/cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.28",
|
|
4
4
|
"description": "Global CLI for SwarmVault.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"typecheck": "tsc --noEmit"
|
|
44
44
|
},
|
|
45
45
|
"dependencies": {
|
|
46
|
-
"@swarmvaultai/engine": "0.1.
|
|
46
|
+
"@swarmvaultai/engine": "0.1.28",
|
|
47
47
|
"commander": "^14.0.1"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|