@sunstack/cli 0.10.0 → 0.11.0

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 CHANGED
@@ -1,5 +1,29 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.11.0
4
+
5
+ Release date: 2026-11-11.
6
+
7
+ - Evidence projects support every built-in ast-grep language, with HTML text
8
+ projected for asking rules while mechanical checks and locations retain source.
9
+ - Cross-document checks add `document` fields, whole-token `contains_field`, and
10
+ `anchor_exists` for HTML IDs. Referenced files share acquisition budgets.
11
+ - `lint --root` checks project files with an external configuration; named paths
12
+ outside the root are invalid, and an empty named selection is incomplete.
13
+
14
+ ## 0.10.1
15
+
16
+ Release date: 2026-11-11.
17
+
18
+ - `lint --since` skips unchanged binary files before decoding textual change
19
+ witnesses. Changed non-UTF-8 content still refuses capture; file and byte
20
+ limits and mutable-source verification still include unchanged binary reads.
21
+ - Change capture compares worktree symlinks by their Git link payload without
22
+ following the target, and verifies both payload and file type.
23
+ - Known limit: on a large repository with an all-files binding, `--since` can
24
+ still stop at the change-discovery limit (exit 3). Change discovery is
25
+ addressed in a later release.
26
+
3
27
  ## 0.10.0
4
28
 
5
29
  Release date: 2026-11-08.
package/README.md CHANGED
@@ -77,10 +77,27 @@ returns yes only for an uncut available field whose loaded targets resolved and
77
77
  have uncut openings. A resolved skill-name load now has an opening too.
78
78
 
79
79
  Rulebook and ast-grep project paths resolve relative to the configuration file.
80
- Checked-file globs resolve from its Git repository root, or from the config
81
- directory outside Git. Without `--config`, lint searches the current directory
80
+ By default, checked-file globs resolve from the config's Git workdir, or from
81
+ its directory outside Git. Without `--config`, lint searches the current directory
82
82
  and its parents for `sunstack.lint.json`.
83
83
 
84
+ Use `--root DIR` with ordinary lint to check a project using a config stored
85
+ elsewhere. The checked root controls `check.files` and `check.ignore` globs,
86
+ reported paths, and containment for `target` and `document` fields. Config-relative
87
+ rulebook and evidence paths still resolve from the config file. For example:
88
+
89
+ ```sh
90
+ sunstack lint --config /path/to/rulebook/sunstack.lint.json --root /path/to/project --all
91
+ ```
92
+
93
+ A named path outside the checked root is invalid (exit 2); the diagnostic names
94
+ the path and root. Named paths inside the root that select no files produce an
95
+ incomplete result (exit 3). With no named paths, an empty selection retains the
96
+ `nothing_selected` status. `--root` is refused with `lint cases`, which uses its
97
+ own historical snapshot root. With `--since`, the checked root must be the Git
98
+ workdir; change scope with an explicit subdirectory root is invalid. Use `--all`
99
+ for that subdirectory instead.
100
+
84
101
  ```sh
85
102
  sunstack lint --config sunstack.lint.json --check
86
103
  sunstack lint --config sunstack.lint.json --all --evidence
@@ -245,6 +262,44 @@ for a complete test example. Copy the fixture directory to an isolated root to
245
262
  try it; its checked-file globs are relative to that root. The example's
246
263
  skill-specific rules are test content.
247
264
 
265
+ ## HTML evidence
266
+
267
+ For the `requirement-row` and `whole-document` HTML ast-grep rules in the
268
+ [HTML evidence guide](../sunstack-evidence/docs/html-evidence.md), add this kind
269
+ to `evidence.kinds`:
270
+
271
+ ```json
272
+ {
273
+ "requirement": {
274
+ "rule": "requirement-row",
275
+ "fields": {
276
+ "identifier": { "from": "capture", "regex": "id=\"(R[0-9]+)\"" },
277
+ "body": { "from": "remainder" },
278
+ "links": { "from": "target", "regex": "href=\"([^\"]+)\"", "resolve": "path" },
279
+ "verification": { "from": "document", "path": "verification-design.html", "rule": "whole-document" }
280
+ }
281
+ }
282
+ }
283
+ ```
284
+
285
+ The example regex requires a nonempty link. To catch `href=""`, use `*` in
286
+ place of `+` in its capture group. An empty captured target is unavailable
287
+ (`empty_target`) and makes the rule incomplete.
288
+
289
+ In rulebook decision steps, check the row's links forward and its identifier
290
+ against the verification document in reverse:
291
+
292
+ ```json
293
+ { "mechanical_check": { "tool": "anchor_exists", "field": "links" }, "yes": "pass", "no": { "finding": "The link target or fragment is missing." } }
294
+ ```
295
+
296
+ ```json
297
+ { "mechanical_check": { "tool": "contains_field", "field": "verification", "needle": "identifier" }, "yes": "pass", "no": { "finding": "The requirement has no verification coverage." } }
298
+ ```
299
+
300
+ The guide explains path resolution, whole-token matching, parse policy, and
301
+ limits of HTML anchor and model-text handling.
302
+
248
303
  ## Selected and contained evidence
249
304
 
250
305
  Add `select` to an evidence kind to ask one noul question about each mechanical
@@ -19,7 +19,7 @@
19
19
  "hasInstallScript": true,
20
20
  "license": "MIT",
21
21
  "name": "@sunstack/cli",
22
- "version": "0.10.0"
22
+ "version": "0.11.0"
23
23
  },
24
24
  "node_modules/detect-libc": {
25
25
  "engines": {
@@ -48,5 +48,5 @@
48
48
  }
49
49
  },
50
50
  "requires": true,
51
- "version": "0.10.0"
51
+ "version": "0.11.0"
52
52
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "artifactDownloadUrls": [
3
- "https://github.com/ShravanSunder/sunstack-tools/releases/download/v0.10.0"
3
+ "https://github.com/ShravanSunder/sunstack-tools/releases/download/v0.11.0"
4
4
  ],
5
5
  "bin": {
6
6
  "sunstack": "run-sunstack.js"
@@ -88,7 +88,7 @@
88
88
  "zipExt": ".tar.gz"
89
89
  }
90
90
  },
91
- "version": "0.10.0",
91
+ "version": "0.11.0",
92
92
  "volta": {
93
93
  "node": "18.14.1",
94
94
  "npm": "9.5.0"