@cortexkit/aft 0.47.0 → 0.47.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/dist/index.js +46 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -1716,10 +1716,11 @@ function formatCallgraphSections(op, response, theme = PLAIN_CALLGRAPH_THEME, op
|
|
|
1716
1716
|
const warning = depthWarning(record, theme, "max_depth_reached", "truncated_paths");
|
|
1717
1717
|
const hubSummary = hubSummaryLine(record, theme);
|
|
1718
1718
|
const totalPaths = asNumber(record.total_paths) ?? paths.length;
|
|
1719
|
+
const totalPathsIsLowerBound = asBoolean(record.total_paths_is_lower_bound) ?? false;
|
|
1719
1720
|
const entryPoints = asNumber(record.entry_points_found) ?? 0;
|
|
1720
1721
|
const sections2 = [
|
|
1721
1722
|
joinNonEmpty([
|
|
1722
|
-
theme.fg("success", `${totalPaths} path${totalPaths === 1 ? "" : "s"}`),
|
|
1723
|
+
theme.fg("success", `${totalPathsIsLowerBound ? "at least " : ""}${totalPaths} path${totalPaths === 1 ? "" : "s"}`),
|
|
1723
1724
|
theme.fg("muted", `${entryPoints} entry point${entryPoints === 1 ? "" : "s"}`),
|
|
1724
1725
|
warning
|
|
1725
1726
|
])
|
|
@@ -2535,6 +2536,49 @@ function markAnnouncementSeen(storageRoot, harness, currentVersion) {
|
|
|
2535
2536
|
writeFileSync(versionFile, currentVersion);
|
|
2536
2537
|
} catch {}
|
|
2537
2538
|
}
|
|
2539
|
+
function decodeFileUrl(target) {
|
|
2540
|
+
if (!target.startsWith("file:"))
|
|
2541
|
+
return target;
|
|
2542
|
+
const rest = target.slice("file:".length);
|
|
2543
|
+
let pathPart;
|
|
2544
|
+
if (rest.startsWith("//")) {
|
|
2545
|
+
const after = rest.slice(2);
|
|
2546
|
+
const slash = after.indexOf("/");
|
|
2547
|
+
const authority = slash === -1 ? after : after.slice(0, slash);
|
|
2548
|
+
const p = slash === -1 ? "" : after.slice(slash);
|
|
2549
|
+
if (authority === "" || authority === "localhost")
|
|
2550
|
+
pathPart = p;
|
|
2551
|
+
else if (process.platform === "win32")
|
|
2552
|
+
pathPart = `//${authority}${p}`;
|
|
2553
|
+
else
|
|
2554
|
+
return target;
|
|
2555
|
+
} else if (rest.startsWith("/")) {
|
|
2556
|
+
pathPart = rest;
|
|
2557
|
+
} else {
|
|
2558
|
+
return target;
|
|
2559
|
+
}
|
|
2560
|
+
const bytes = [];
|
|
2561
|
+
for (let i = 0;i < pathPart.length; ) {
|
|
2562
|
+
if (pathPart[i] === "%" && i + 2 < pathPart.length) {
|
|
2563
|
+
const hex = pathPart.slice(i + 1, i + 3);
|
|
2564
|
+
if (/^[0-9a-fA-F]{2}$/.test(hex)) {
|
|
2565
|
+
bytes.push(Number.parseInt(hex, 16));
|
|
2566
|
+
i += 3;
|
|
2567
|
+
continue;
|
|
2568
|
+
}
|
|
2569
|
+
}
|
|
2570
|
+
const cp = pathPart.codePointAt(i);
|
|
2571
|
+
const ch = String.fromCodePoint(cp);
|
|
2572
|
+
for (const b of Buffer.from(ch, "utf8"))
|
|
2573
|
+
bytes.push(b);
|
|
2574
|
+
i += ch.length;
|
|
2575
|
+
}
|
|
2576
|
+
const decoded = Buffer.from(bytes).toString("utf8");
|
|
2577
|
+
if (process.platform === "win32" && /^\/[A-Za-z]:/.test(decoded)) {
|
|
2578
|
+
return decoded.slice(1);
|
|
2579
|
+
}
|
|
2580
|
+
return decoded;
|
|
2581
|
+
}
|
|
2538
2582
|
var init_paths = () => {};
|
|
2539
2583
|
|
|
2540
2584
|
// ../aft-bridge/dist/resolver.js
|
|
@@ -7546,6 +7590,7 @@ __export(exports_dist, {
|
|
|
7546
7590
|
ensureOnnxRuntime: () => ensureOnnxRuntime,
|
|
7547
7591
|
ensureBinary: () => ensureBinary,
|
|
7548
7592
|
downloadBinary: () => downloadBinary,
|
|
7593
|
+
decodeFileUrl: () => decodeFileUrl,
|
|
7549
7594
|
createStatusBarEmitState: () => createStatusBarEmitState,
|
|
7550
7595
|
createAftTransportPool: () => createAftTransportPool,
|
|
7551
7596
|
compressionSavingsPercent: () => compressionSavingsPercent,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cortexkit/aft",
|
|
3
|
-
"version": "0.47.
|
|
3
|
+
"version": "0.47.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Unified CLI for Agent File Tools (AFT) — setup, doctor, and diagnostics across supported agent harnesses (OpenCode, Pi)",
|
|
6
6
|
"license": "MIT",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
},
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@clack/prompts": "^1.6.0",
|
|
27
|
-
"@cortexkit/aft-bridge": "0.47.
|
|
27
|
+
"@cortexkit/aft-bridge": "0.47.2",
|
|
28
28
|
"comment-json": "^4.6.2"
|
|
29
29
|
},
|
|
30
30
|
"devDependencies": {
|