jinzd-ai-cli 0.1.46 → 0.1.47
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/dist/index.js
CHANGED
|
@@ -29,7 +29,7 @@ import {
|
|
|
29
29
|
SUBAGENT_MAX_ROUNDS_LIMIT,
|
|
30
30
|
VERSION,
|
|
31
31
|
runTestsTool
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-ZUZDWQVG.js";
|
|
33
33
|
|
|
34
34
|
// src/index.ts
|
|
35
35
|
import { program } from "commander";
|
|
@@ -1924,7 +1924,12 @@ var SessionManager = class {
|
|
|
1924
1924
|
if (!existsSync2(filePath)) {
|
|
1925
1925
|
throw new Error(`Session ${id} not found`);
|
|
1926
1926
|
}
|
|
1927
|
-
|
|
1927
|
+
let data;
|
|
1928
|
+
try {
|
|
1929
|
+
data = JSON.parse(readFileSync2(filePath, "utf-8"));
|
|
1930
|
+
} catch (err) {
|
|
1931
|
+
throw new Error(`Session ${id} is corrupted: ${err instanceof Error ? err.message : String(err)}`);
|
|
1932
|
+
}
|
|
1928
1933
|
const session = Session.fromJSON(data);
|
|
1929
1934
|
this._current = session;
|
|
1930
1935
|
return session;
|
|
@@ -2950,8 +2955,15 @@ function scanDirTree(dir, maxDepth = 2, maxEntries = 80) {
|
|
|
2950
2955
|
}
|
|
2951
2956
|
const filtered = entries.filter((e) => !e.startsWith(".") && !SCAN_SKIP_DIRS.has(e));
|
|
2952
2957
|
const sorted = filtered.sort((a, b) => {
|
|
2953
|
-
|
|
2954
|
-
|
|
2958
|
+
let aIsDir = false, bIsDir = false;
|
|
2959
|
+
try {
|
|
2960
|
+
aIsDir = statSync2(join5(d, a)).isDirectory();
|
|
2961
|
+
} catch {
|
|
2962
|
+
}
|
|
2963
|
+
try {
|
|
2964
|
+
bIsDir = statSync2(join5(d, b)).isDirectory();
|
|
2965
|
+
} catch {
|
|
2966
|
+
}
|
|
2955
2967
|
if (aIsDir !== bIsDir) return aIsDir ? -1 : 1;
|
|
2956
2968
|
return a.localeCompare(b);
|
|
2957
2969
|
});
|
|
@@ -4161,7 +4173,7 @@ ${hint}` : "")
|
|
|
4161
4173
|
description: "Run project tests and show structured report",
|
|
4162
4174
|
usage: "/test [command|filter]",
|
|
4163
4175
|
async execute(args, _ctx) {
|
|
4164
|
-
const { executeTests } = await import("./run-tests-
|
|
4176
|
+
const { executeTests } = await import("./run-tests-EM3QNRWV.js");
|
|
4165
4177
|
const argStr = args.join(" ").trim();
|
|
4166
4178
|
let testArgs = {};
|
|
4167
4179
|
if (argStr) {
|
|
@@ -9106,17 +9118,17 @@ Session '${this.resumeSessionId}' not found.
|
|
|
9106
9118
|
this.renderer.renderError(err);
|
|
9107
9119
|
} finally {
|
|
9108
9120
|
processing = false;
|
|
9109
|
-
|
|
9110
|
-
|
|
9111
|
-
|
|
9112
|
-
|
|
9113
|
-
|
|
9114
|
-
|
|
9115
|
-
|
|
9116
|
-
|
|
9117
|
-
|
|
9118
|
-
|
|
9119
|
-
|
|
9121
|
+
if (this.running) {
|
|
9122
|
+
rlAny.output = savedOutput;
|
|
9123
|
+
const rlInternal = this.rl;
|
|
9124
|
+
rlInternal.line = "";
|
|
9125
|
+
rlInternal.cursor = 0;
|
|
9126
|
+
rlInternal.paused = false;
|
|
9127
|
+
process.stdin.resume();
|
|
9128
|
+
this.showPrompt();
|
|
9129
|
+
} else {
|
|
9130
|
+
resolve5();
|
|
9131
|
+
}
|
|
9120
9132
|
}
|
|
9121
9133
|
});
|
|
9122
9134
|
this.rl.on("close", () => {
|