@rune-kit/rune 2.28.0 → 2.29.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.
Files changed (51) hide show
  1. package/.codex-plugin/plugin.json +14 -0
  2. package/README.md +114 -41
  3. package/compiler/__tests__/adapter-model-mapping.test.js +22 -24
  4. package/compiler/__tests__/adapters.test.js +4 -1
  5. package/compiler/__tests__/doctor-mesh.test.js +55 -1
  6. package/compiler/__tests__/governance-collector.test.js +1 -0
  7. package/compiler/__tests__/hooks-codex.test.js +85 -0
  8. package/compiler/__tests__/hooks-doctor-tier.test.js +3 -5
  9. package/compiler/__tests__/hooks-drift.test.js +2 -2
  10. package/compiler/__tests__/hooks-install.test.js +2 -2
  11. package/compiler/__tests__/hooks-tiers.test.js +3 -4
  12. package/compiler/__tests__/setup.test.js +59 -0
  13. package/compiler/__tests__/status.test.js +7 -1
  14. package/compiler/__tests__/tier-override.test.js +42 -1
  15. package/compiler/__tests__/transforms.test.js +15 -0
  16. package/compiler/__tests__/update.test.js +416 -0
  17. package/compiler/adapters/codex.js +88 -11
  18. package/compiler/adapters/hooks/codex.js +178 -0
  19. package/compiler/adapters/hooks/index.js +10 -0
  20. package/compiler/adapters/openclaw.js +2 -2
  21. package/compiler/bin/rune.js +24 -4
  22. package/compiler/commands/hooks/install.js +2 -2
  23. package/compiler/commands/hooks/status.js +1 -1
  24. package/compiler/commands/setup.js +101 -28
  25. package/compiler/commands/update.js +354 -0
  26. package/compiler/doctor.js +12 -6
  27. package/compiler/emitter.js +46 -3
  28. package/compiler/governance-collector.js +3 -2
  29. package/compiler/status.js +4 -7
  30. package/compiler/transforms/branding.js +2 -2
  31. package/compiler/transforms/subagents.js +3 -3
  32. package/hooks/codex-hooks.json +96 -0
  33. package/hooks/context-watch/index.cjs +8 -5
  34. package/hooks/intent-router/index.cjs +3 -0
  35. package/hooks/lib/hook-output.cjs +11 -3
  36. package/hooks/post-session-reflect/index.cjs +65 -24
  37. package/hooks/pre-compact/index.cjs +10 -4
  38. package/hooks/pre-tool-guard/index.cjs +38 -36
  39. package/hooks/run-hook +1 -1
  40. package/hooks/run-hook.cmd +1 -1
  41. package/hooks/secrets-scan/index.cjs +18 -2
  42. package/package.json +3 -2
  43. package/skills/browser-pilot/SKILL.md +1 -0
  44. package/skills/completion-gate/SKILL.md +5 -5
  45. package/skills/doc-processor/SKILL.md +2 -2
  46. package/skills/hallucination-guard/SKILL.md +1 -0
  47. package/skills/journal/SKILL.md +1 -0
  48. package/skills/retro/SKILL.md +2 -2
  49. package/skills/session-bridge/SKILL.md +1 -0
  50. package/skills/session-bridge/scripts/load-invariants.js +1 -1
  51. package/skills/video-creator/SKILL.md +1 -1
@@ -6,10 +6,26 @@
6
6
  // Zero false-positive tolerance on BLOCK patterns.
7
7
 
8
8
  const { execSync } = require('child_process');
9
+ const fs = require('fs');
10
+ const { captureConsole } = require('../lib/hook-output.cjs');
11
+
12
+ captureConsole('PreToolUse', { captureError: true });
9
13
 
10
14
  // Only intercept git commit commands
11
- const input = JSON.parse(process.env.CLAUDE_TOOL_INPUT || '{}');
12
- const command = (input.command || '').trim();
15
+ let rawInput = '';
16
+ try {
17
+ rawInput = fs.readFileSync(0, 'utf-8');
18
+ } catch {
19
+ // Claude compatibility fallback below.
20
+ }
21
+ let event = {};
22
+ try {
23
+ event = JSON.parse(rawInput.trim() || process.env.CLAUDE_TOOL_INPUT || '{}');
24
+ } catch {
25
+ process.exit(0);
26
+ }
27
+ const toolInput = event.tool_input || event;
28
+ const command = (toolInput.command || '').trim();
13
29
 
14
30
  // Check if this is a git commit command
15
31
  if (!/^git\s+commit\b/.test(command)) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@rune-kit/rune",
3
- "version": "2.28.0",
4
- "description": "65-skill mesh for AI coding assistants — runtime auto-discipline via native hooks (Claude/Cursor/Windsurf/Antigravity), 5-layer architecture, 204 connections + 43 signals, multi-platform compiler. converge (L3) scans spec vs code so dead-button/frontend-only implementations can't ship.",
3
+ "version": "2.29.1",
4
+ "description": "66-skill mesh for AI coding assistants — native lifecycle hooks for Claude Code and Codex, 5-layer architecture, 248 connections + 45 signals, and a 13-platform compiler.",
5
5
  "type": "module",
6
6
  "bin": {
7
7
  "rune": "./compiler/bin/rune.js"
@@ -52,6 +52,7 @@
52
52
  "commands/",
53
53
  "agents/",
54
54
  "hooks/",
55
+ ".codex-plugin/",
55
56
  "references/"
56
57
  ],
57
58
  "homepage": "https://rune-kit.github.io/rune",
@@ -25,6 +25,7 @@ Browser automation for testing and verification using MCP Playwright tools. Navi
25
25
  - `launch` (L1): verify live site after deployment
26
26
  - `perf` (L2): Lighthouse / Core Web Vitals measurement
27
27
  - `audit` (L2): visual verification during quality assessment
28
+ - `design` (L2): render the surface before any visual property is claimed (design Step 5.4 — render blindness)
28
29
 
29
30
  ## Calls (outbound)
30
31
 
@@ -148,11 +148,11 @@ For each claim, look for corresponding evidence in the conversation context:
148
148
 
149
149
  | Claim Type | Required Evidence | Where to Find |
150
150
  |---|---|---|
151
- | "tests pass" | Test runner stdout with pass count | Bash output from test command |
152
- | "build succeeds" | Build command stdout showing success | Bash output from build command |
153
- | "lint clean" | Linter stdout (even if empty = 0 errors) | Bash output from lint command |
154
- | "fixed" | Git diff showing the change + test proving fix | Edit/Write tool calls + test output |
155
- | "implemented" | Files created/modified matching the plan | Write/Edit tool calls vs plan |
151
+ | "tests pass" | Test runner stdout with pass count | Shell output from test command |
152
+ | "build succeeds" | Build command stdout showing success | Shell output from build command |
153
+ | "lint clean" | Linter stdout (even if empty = 0 errors) | Shell output from lint command |
154
+ | "fixed" | Git diff showing the change + test proving fix | File-edit evidence + test output |
155
+ | "implemented" | Files created/modified matching the plan | File changes compared with the plan |
156
156
  | "no security issues" | Sentinel report with PASS verdict | Sentinel skill output |
157
157
  | "coverage ≥ X%" | Coverage tool output with actual percentage | Test runner with coverage flag |
158
158
 
@@ -41,7 +41,7 @@ None — pure L3 utility. Receives content, produces formatted output.
41
41
 
42
42
  | Format | Generate | Parse | Node.js Library | Python Library |
43
43
  |--------|----------|-------|-----------------|----------------|
44
- | PDF | Yes | Yes (via Read tool) | jsPDF, Puppeteer (HTML→PDF) | reportlab, weasyprint |
44
+ | PDF | Yes | Yes (via the runtime's document/PDF reader) | jsPDF, Puppeteer (HTML→PDF) | reportlab, weasyprint |
45
45
  | DOCX | Yes | Yes | docx (officegen) | python-docx |
46
46
  | XLSX | Yes | Yes | ExcelJS | openpyxl |
47
47
  | PPTX | Yes | Yes | pptxgenjs | python-pptx |
@@ -157,7 +157,7 @@ Identify file format from extension and MIME type.
157
157
 
158
158
  | Format | Extraction Strategy |
159
159
  |--------|-------------------|
160
- | PDF | Use Read tool (Claude can read PDFs natively) |
160
+ | PDF | Use the runtime's native document/PDF reader when available; otherwise use a supported PDF parsing library |
161
161
  | DOCX | docx library → extract text, tables, images |
162
162
  | XLSX | ExcelJS → extract sheets, rows, formulas |
163
163
  | PPTX | pptxgenjs → extract slides, text, notes |
@@ -39,6 +39,7 @@ Post-generation validation that verifies AI-generated code references actually e
39
39
  - `review-intake` (L2): verify imports in code submitted for review
40
40
  - `skill-forge` (L2): verify imports in newly generated skill code
41
41
  - `adversary` (L2): verify APIs/packages in plan actually exist
42
+ - `logic-guardian` (L2): verify referenced functions and imports after guarded logic edits
42
43
 
43
44
  ## Execution
44
45
 
@@ -39,6 +39,7 @@ None — pure L3 state management utility.
39
39
  - `graft` (L2): auto-log graft operations — source URL, mode, challenge score, files changed
40
40
  - `retro` (L2): record retrospective insights and decisions
41
41
  - `improve-architecture` (L2): record an ADR when the user rejects a deepening candidate with a load-bearing reason
42
+ - `logic-guardian` (L2): record guarded logic changes for cross-session persistence
42
43
 
43
44
  ## Files Managed
44
45
 
@@ -316,8 +316,8 @@ Pull from all installed domain packs:
316
316
  - **Engineering**: git history (commits, velocity, test ratio, fix ratio, hotspots)
317
317
  - **Revenue** (@rune-pro/sales): pipeline metrics, deal velocity, churn risk
318
318
  - **Support** (@rune-pro/support): ticket volume, SLA compliance, CSAT
319
- - **Finance** (@rune-business/finance): burn rate, runway, budget variance
320
- - **Compliance** (@rune-business/legal): framework status, audit dates, open items
319
+ - **Finance** (@rune-pro/finance): burn rate, runway, budget variance
320
+ - **Compliance** (@rune-pro/legal): framework status, audit dates, open items
321
321
 
322
322
  ### Business Execution Steps
323
323
 
@@ -41,6 +41,7 @@ Solve the #1 developer complaint: context loss across sessions. Session-bridge a
41
41
  - `context-pack` (L3): coordinate state for sub-agent handoff
42
42
  - `neural-memory` (L3): sync key decisions back to `.rune/` files after Capture Mode
43
43
  - `adversary` (L2): (oracle-mode) detach protocol when target model is opus-class for non-blocking dispatch
44
+ - `logic-guardian` (L2): preserve logic-manifest state across sessions
44
45
 
45
46
  ## State Files Managed
46
47
 
@@ -132,7 +132,7 @@ export function parseInvariants(text) {
132
132
  let current = null;
133
133
 
134
134
  const flush = () => {
135
- if (current && current.title) rules.push(current);
135
+ if (current?.title) rules.push(current);
136
136
  current = null;
137
137
  };
138
138
 
@@ -265,7 +265,7 @@ Known failure modes for this skill. Check these before declaring done.
265
265
  - Storyboard created scene-by-scene with transitions
266
266
  - Shot list categorized by type (screen recording, terminal, code, diagram)
267
267
  - Assets needed checklist generated
268
- - video-plan.md written to output_path via Write tool
268
+ - `video-plan.md` written to `output_path` with the runtime's file-edit capability
269
269
  - Video Plan Created report emitted with scene count, shot count, and asset count
270
270
 
271
271
  ## Cost Profile