@joeyshi12/casper 0.11.0 → 0.11.1
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 +2 -0
- package/dist/mcp.js +1 -1
- package/dist/server.js +8 -10
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -34,6 +34,8 @@ Needs Node 24+, since Casper keeps its state in SQLite via the built-in
|
|
|
34
34
|
`node:sqlite`. It also needs [`kiro-cli`](https://kiro.dev) installed and logged in.
|
|
35
35
|
Casper is a client for it, so nothing works without it.
|
|
36
36
|
|
|
37
|
+
**kiro-cli 2.x, tested against 2.11 to 2.19. Not yet compatible with 3.0.**
|
|
38
|
+
|
|
37
39
|
```bash
|
|
38
40
|
npm install -g @joeyshi12/casper
|
|
39
41
|
casper
|
package/dist/mcp.js
CHANGED
|
@@ -369,7 +369,7 @@ function handleMessage(req, version) {
|
|
|
369
369
|
}
|
|
370
370
|
|
|
371
371
|
// server/src/mcp/server.ts
|
|
372
|
-
var VERSION = true ? "0.11.
|
|
372
|
+
var VERSION = true ? "0.11.1" : "dev";
|
|
373
373
|
function runMcpServer() {
|
|
374
374
|
const rl = createInterface({ input: process.stdin });
|
|
375
375
|
rl.on("line", (line) => {
|
package/dist/server.js
CHANGED
|
@@ -770,7 +770,6 @@ function invalidateAgents() {
|
|
|
770
770
|
async function listAgents() {
|
|
771
771
|
if (cache && Date.now() - cache.at < CACHE_TTL_MS) return cache.agents;
|
|
772
772
|
const found = /* @__PURE__ */ new Map();
|
|
773
|
-
for (const b of BUILTIN) found.set(b.id, b);
|
|
774
773
|
try {
|
|
775
774
|
const { stdout, stderr } = await execFileAsync(config.kiroBin, ["agent", "list"], {
|
|
776
775
|
cwd: config.defaultCwd,
|
|
@@ -779,7 +778,7 @@ async function listAgents() {
|
|
|
779
778
|
const text2 = (stderr || "") + "\n" + (stdout || "");
|
|
780
779
|
for (const rawLine of text2.split("\n")) {
|
|
781
780
|
const line = rawLine.replace(ANSI, "");
|
|
782
|
-
const m = /^\s{0,2}(\*\s)?([A-Za-z0-9_-]+)\s{2,}(Global|Workspace|Local)
|
|
781
|
+
const m = /^\s{0,2}(\*\s)?([A-Za-z0-9_-]+)\s{2,}(\(Built-in\)|Global|Workspace|Local)(?:\s|$)/.exec(
|
|
783
782
|
line
|
|
784
783
|
);
|
|
785
784
|
if (!m) continue;
|
|
@@ -788,19 +787,18 @@ async function listAgents() {
|
|
|
788
787
|
}
|
|
789
788
|
} catch {
|
|
790
789
|
}
|
|
791
|
-
|
|
790
|
+
const agents = found.size > 0 ? [...found.values()] : FALLBACK;
|
|
791
|
+
cache = { at: Date.now(), agents };
|
|
792
792
|
return cache.agents;
|
|
793
793
|
}
|
|
794
|
-
var execFileAsync,
|
|
794
|
+
var execFileAsync, FALLBACK, CACHE_TTL_MS, cache, ANSI;
|
|
795
795
|
var init_agents = __esm({
|
|
796
796
|
"server/src/session/agents.ts"() {
|
|
797
797
|
"use strict";
|
|
798
798
|
init_config();
|
|
799
799
|
execFileAsync = promisify(execFile);
|
|
800
|
-
|
|
801
|
-
{ id: "kiro_default", name: "kiro_default", description: "General-purpose Kiro agent" }
|
|
802
|
-
{ id: "kiro_planner", name: "kiro_planner", description: "Planning-focused agent" },
|
|
803
|
-
{ id: "kiro_guide", name: "kiro_guide", description: "Guidance and Q&A agent" }
|
|
800
|
+
FALLBACK = [
|
|
801
|
+
{ id: "kiro_default", name: "kiro_default", description: "General-purpose Kiro agent" }
|
|
804
802
|
];
|
|
805
803
|
CACHE_TTL_MS = 15e3;
|
|
806
804
|
cache = null;
|
|
@@ -4115,7 +4113,7 @@ var init_server2 = __esm({
|
|
|
4115
4113
|
"server/src/mcp/server.ts"() {
|
|
4116
4114
|
"use strict";
|
|
4117
4115
|
init_protocol();
|
|
4118
|
-
VERSION = true ? "0.11.
|
|
4116
|
+
VERSION = true ? "0.11.1" : "dev";
|
|
4119
4117
|
}
|
|
4120
4118
|
});
|
|
4121
4119
|
|
|
@@ -7495,7 +7493,7 @@ var program = new Command();
|
|
|
7495
7493
|
// server/src/cli/program.ts
|
|
7496
7494
|
init_paths();
|
|
7497
7495
|
init_settings();
|
|
7498
|
-
var VERSION2 = true ? "0.11.
|
|
7496
|
+
var VERSION2 = true ? "0.11.1" : "dev";
|
|
7499
7497
|
async function bootstrap() {
|
|
7500
7498
|
const file = configFilePath();
|
|
7501
7499
|
const settings = readSettings(file);
|