arkgate 2.4.0 → 2.6.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 +46 -0
- package/README.md +2 -1
- package/bin/ark-check.mjs +194 -3867
- package/bin/ark-layer-match.mjs +168 -0
- package/bin/ark-shared.mjs +8 -131
- package/bin/lib/agent-gates.mjs +1550 -0
- package/bin/lib/doctor-plan.mjs +503 -0
- package/bin/lib/html-report.mjs +1301 -0
- package/bin/lib/presets.mjs +244 -0
- package/bin/lib/suggestions.mjs +109 -0
- package/bin/lib/violations.mjs +170 -0
- package/dist/eslint/index.cjs +263 -23
- package/dist/eslint/index.cjs.map +1 -1
- package/dist/eslint/index.d.cts +54 -1
- package/dist/eslint/index.d.ts +54 -1
- package/dist/eslint/index.js +245 -22
- package/dist/eslint/index.js.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/nestjs/index.cjs +1 -1
- package/dist/nestjs/index.cjs.map +1 -1
- package/dist/nestjs/index.js +1 -1
- package/dist/nestjs/index.js.map +1 -1
- package/docs/agent-guide.md +4 -3
- package/docs/ai-gates.md +15 -29
- package/package.json +2 -1
- package/server.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,52 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to ArkGate (`arkgate`; formerly `ark-runtime-kernel`) are documented here.
|
|
4
4
|
|
|
5
|
+
## 2.6.0 — 2026-07-09
|
|
6
|
+
|
|
7
|
+
### Changed — maintainability hygiene (#11 / #12)
|
|
8
|
+
|
|
9
|
+
- **`bin/ark-check.mjs` modularized** (~5.8k → ~2.1k lines of orchestration):
|
|
10
|
+
`bin/lib/agent-gates.mjs`, `html-report.mjs`, `doctor-plan.mjs`, `violations.mjs`,
|
|
11
|
+
`suggestions.mjs`, `presets.mjs`. Entry owns scan/CLI only.
|
|
12
|
+
- **Layer matching single algorithm:** pure matcher in `bin/ark-layer-match.mjs` (CLI) and
|
|
13
|
+
`src/domain/layerMatch.ts` (eslint). Tooling may import DomainModel for that pure helper.
|
|
14
|
+
`tests/unit/static-check/layerMatchParity.test.ts` locks both implementations.
|
|
15
|
+
- Dual-driver ESLint/CI tests retained.
|
|
16
|
+
|
|
17
|
+
### Fixed — field test (Codex + Grok on random repos)
|
|
18
|
+
|
|
19
|
+
- **`--report` path display:** absolute report paths no longer print as brittle
|
|
20
|
+
`../../../../tmp/...` relatives; paths outside the project root print absolute.
|
|
21
|
+
- **`ark-check --help`:** documents dual bins `arkgate-check | ark-check`.
|
|
22
|
+
- **`ark-check --version` / `-V`:** prints package version (no longer runs a full check).
|
|
23
|
+
- **Doctor thin-coverage honesty:** when there are zero violations but governed < 50%
|
|
24
|
+
(or empty scope), doctor no longer claims “code matches the contract”; it warns that
|
|
25
|
+
green is not yet honest enforcement.
|
|
26
|
+
- **Grok write-gate hooks:** root env
|
|
27
|
+
`${GROK_WORKSPACE_ROOT:-${CLAUDE_PROJECT_DIR:-.}}` (Grok → Claude alias → cwd).
|
|
28
|
+
- **AGENTS / package / Cursor check command:** if `.ark-baseline.json` exists, emitted
|
|
29
|
+
`ark-check` commands include `--baseline .ark-baseline.json` (same ratchet as CI).
|
|
30
|
+
|
|
31
|
+
## 2.5.0 — 2026-07-09
|
|
32
|
+
|
|
33
|
+
### Added — ESLint ↔ CI layer parity
|
|
34
|
+
|
|
35
|
+
- **`arkgate/eslint`** `no-domain-infra-imports` is **config-driven**: loads
|
|
36
|
+
`ark.config.json` (walk-up from the linted file), classifies layers with the same
|
|
37
|
+
glob specificity + `exclude` semantics as `arkgate-check`, and denies edges from
|
|
38
|
+
`rules[]` — not path-token “domain/infra” heuristics alone.
|
|
39
|
+
- Relative imports resolve to on-disk TS/JS targets; type-only and value imports both
|
|
40
|
+
fail when the edge is denied (same pass/fail as CI).
|
|
41
|
+
- **`no-forbidden-globals`** reads `forbiddenGlobals` from the matched layer in
|
|
42
|
+
`ark.config.json` (no invented defaults for layers without a purity list). Optional
|
|
43
|
+
rule option `globals` still overrides. Domain path heuristic + defaults only when
|
|
44
|
+
no config is found.
|
|
45
|
+
- Dual-driver tests: same fixtures → ESLint rule + `ark-check --json` agree.
|
|
46
|
+
- Recommended config enables `ark/no-forbidden-globals`.
|
|
47
|
+
- Without `ark.config.json`, legacy domain→infra path heuristic remains for bare trees.
|
|
48
|
+
- **ESLint 8–10 filename API:** rules read `physicalFilename` → `filename` → `getFilename()`
|
|
49
|
+
so config walk-up works on ESLint 10 (where `getFilename` was removed).
|
|
50
|
+
|
|
5
51
|
## 2.4.0 — 2026-07-08
|
|
6
52
|
|
|
7
53
|
### Added — Adoption completeness (P0–P2)
|
package/README.md
CHANGED
|
@@ -167,6 +167,7 @@ ark.config.json
|
|
|
167
167
|
| Classified plan (`mechanical-safe` / judgment) | ✅ | ❌ |
|
|
168
168
|
| TypeScript 5 / 6 / 7 project compilers | ✅ | varies |
|
|
169
169
|
| Adoption scorecard (hosts / MCP / origin) | ✅ | ❌ |
|
|
170
|
+
| **Editor ESLint same layer contract as CI** | ✅ (`arkgate/eslint`) | varies |
|
|
170
171
|
|
|
171
172
|
---
|
|
172
173
|
|
|
@@ -210,7 +211,7 @@ NestJS: `arkgate/nestjs` (optional peer `@nestjs/common`).
|
|
|
210
211
|
| Audience | Link |
|
|
211
212
|
|----------|------|
|
|
212
213
|
| New builders (plain language) | [docs/enthusiast/](docs/enthusiast/README.md) |
|
|
213
|
-
| Wire Claude / Cursor / Codex / Grok | [docs/ai-gates.md](docs/ai-gates.md) |
|
|
214
|
+
| Wire Claude / Cursor / Codex / Grok + **ESLint (CI-parity)** | [docs/ai-gates.md](docs/ai-gates.md) |
|
|
214
215
|
| **TypeScript 5 / 6 / 7 support** | [docs/typescript-support.md](docs/typescript-support.md) |
|
|
215
216
|
| Migrate from `ark-runtime-kernel` | [docs/migrate-from-ark-runtime-kernel.md](docs/migrate-from-ark-runtime-kernel.md) |
|
|
216
217
|
| Messy existing repo | [docs/brownfield-adoption.md](docs/brownfield-adoption.md) |
|