zames_pro 2.80.0 → 2.80.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/CHANGELOG.md +8 -0
- package/dist/context.js +7 -1
- package/dist/diagnostics.js +5 -1
- package/dist/statusline.js +27 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [2.80.1] - 2026-10-20
|
|
11
|
+
|
|
12
|
+
### Fixed
|
|
13
|
+
|
|
14
|
+
- **context:** strip a leading BOM before the SKILL.md frontmatter
|
|
15
|
+
- **statusline:** clip a long status badge to one short row
|
|
16
|
+
- **diagnostics:** keep the summary inside maxChars
|
|
17
|
+
|
|
10
18
|
## [2.80.0] - 2026-10-20
|
|
11
19
|
|
|
12
20
|
### Fixed
|
package/dist/context.js
CHANGED
|
@@ -305,7 +305,13 @@ function parseFrontmatter(raw) {
|
|
|
305
305
|
};
|
|
306
306
|
}
|
|
307
307
|
export function skillBody(raw) {
|
|
308
|
-
|
|
308
|
+
// A leading BOM (some Windows editors and generators write one) makes the
|
|
309
|
+
// text NOT start with `---`, so the frontmatter check below missed it and
|
|
310
|
+
// the model got the raw YAML mixed into the instructions. Drop it first.
|
|
311
|
+
const bom = String.fromCharCode(0xfeff);
|
|
312
|
+
const norm = String(raw ?? '')
|
|
313
|
+
.replace(new RegExp('^' + bom), '')
|
|
314
|
+
.replace(CRLF_RE, NL);
|
|
309
315
|
if (!norm.startsWith('---'))
|
|
310
316
|
return norm.trim();
|
|
311
317
|
const end = norm.indexOf(NL + '---', 3);
|
package/dist/diagnostics.js
CHANGED
|
@@ -47,10 +47,14 @@ export function summarizeDiagnostics(raw, maxChars) {
|
|
|
47
47
|
const chosen = errLines.length ? errLines : lines;
|
|
48
48
|
let out = chosen.join('\n');
|
|
49
49
|
if (out.length > maxChars) {
|
|
50
|
+
// The truncation MARKER is part of the cap, so the head must leave room
|
|
51
|
+
// for it (appending it to a maxChars-long head exceeded the budget).
|
|
52
|
+
const MARKER = '\n… [diagnostics truncated]';
|
|
53
|
+
const budget = Math.max(0, maxChars - MARKER.length);
|
|
50
54
|
// Never split a surrogate PAIR (emoji / astral CJK): the high half alone
|
|
51
55
|
// is a lone surrogate in the model's context. Same rule as
|
|
52
56
|
// truncateToolResult (agent-loop) and capReport (subagent).
|
|
53
|
-
let cut =
|
|
57
|
+
let cut = budget;
|
|
54
58
|
const c = out.charCodeAt(cut - 1);
|
|
55
59
|
if (c >= 0xd800 && c <= 0xdbff)
|
|
56
60
|
cut--;
|
package/dist/statusline.js
CHANGED
|
@@ -1,4 +1,27 @@
|
|
|
1
1
|
import { spawn } from 'node:child_process';
|
|
2
|
+
// N37 statusLine hook. When `ui.statusLineCommand` is set, zames runs it on a
|
|
3
|
+
// timer with a JSON status object on stdin and shows the FIRST line of its
|
|
4
|
+
// stdout in the status line (like Claude Code). The command is deliberately
|
|
5
|
+
// run OUT of the render path: a per-render spawn would block typing, so the
|
|
6
|
+
// caller runs it on its own interval and only sets the resulting text.
|
|
7
|
+
//
|
|
8
|
+
// Best-effort: a missing/failing command yields an empty string (the badge is
|
|
9
|
+
// hidden), never an error in the UI.
|
|
10
|
+
// Longest status text that still fits a typical terminal row together with
|
|
11
|
+
// the rest of the status bar.
|
|
12
|
+
export const STATUS_BADGE_MAX = 80;
|
|
13
|
+
/** Clip a status badge to STATUS_BADGE_MAX with an ellipsis (never splits a
|
|
14
|
+
* surrogate pair). */
|
|
15
|
+
export function clipBadge(text, max = STATUS_BADGE_MAX) {
|
|
16
|
+
const s = String(text ?? '');
|
|
17
|
+
if (s.length <= max)
|
|
18
|
+
return s;
|
|
19
|
+
let cut = max - 1;
|
|
20
|
+
const c = s.charCodeAt(cut - 1);
|
|
21
|
+
if (c >= 0xd800 && c <= 0xdbff)
|
|
22
|
+
cut--;
|
|
23
|
+
return s.slice(0, cut) + '…';
|
|
24
|
+
}
|
|
2
25
|
/** Run the statusLine command and return its first stdout line (trimmed). */
|
|
3
26
|
export function runStatusLineCommand(workdir, command, info, timeoutMs = 4000) {
|
|
4
27
|
return new Promise((resolve) => {
|
|
@@ -24,7 +47,10 @@ export function runStatusLineCommand(workdir, command, info, timeoutMs = 4000) {
|
|
|
24
47
|
return;
|
|
25
48
|
done = true;
|
|
26
49
|
const first = String(out).split(/\r?\n/)[0].trim();
|
|
27
|
-
|
|
50
|
+
// The status line is rendered as ONE row, unwrapped. A command that
|
|
51
|
+
// prints a long single line must not push 400 raw columns into it
|
|
52
|
+
// (the row overflows and the cursor arithmetic drifts).
|
|
53
|
+
resolve(clipBadge(first));
|
|
28
54
|
};
|
|
29
55
|
// Only the FIRST LINE is shown, so there is no reason to keep collecting a
|
|
30
56
|
// big blob: a chatty command (a JSON dump, `ls -R`) would grow `out`
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "zames_pro",
|
|
3
|
-
"version": "2.80.
|
|
3
|
+
"version": "2.80.1",
|
|
4
4
|
"description": "Terminal coding agent that drives a real browser to chat with DeepSeek, Qwen and other web LLMs — no API key required. Reads and edits files, runs commands, commits to git, like Claude Code / Codex CLI.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|