@qball-inc/the-bulwark 1.2.1 → 1.3.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.
Files changed (40) hide show
  1. package/.claude-plugin/plugin.json +50 -42
  2. package/CHANGELOG.md +72 -30
  3. package/CONTRIBUTING.md +52 -0
  4. package/README.md +97 -373
  5. package/hooks/hooks.json +100 -88
  6. package/package.json +46 -46
  7. package/scripts/hooks/bulwark-permission-hook.sh +306 -0
  8. package/skills/anthropic-validator/SKILL.md +6 -0
  9. package/skills/anthropic-validator/references/skills-checklist.md +2 -1
  10. package/skills/anthropic-validator/references/skills-validation.md +2 -1
  11. package/skills/assertion-patterns/SKILL.md +3 -0
  12. package/skills/bug-magnet-data/SKILL.md +3 -0
  13. package/skills/bulwark-brainstorm/SKILL.md +8 -0
  14. package/skills/bulwark-research/SKILL.md +8 -0
  15. package/skills/bulwark-scaffold/SKILL.md +75 -2
  16. package/skills/bulwark-statusline/SKILL.md +3 -1
  17. package/skills/bulwark-verify/SKILL.md +9 -0
  18. package/skills/code-review/SKILL.md +72 -89
  19. package/skills/code-review/references/diagnostic-schema.md +119 -0
  20. package/skills/component-patterns/SKILL.md +3 -0
  21. package/skills/continuous-feedback/SKILL.md +9 -0
  22. package/skills/create-skill/SKILL.md +9 -0
  23. package/skills/create-subagent/SKILL.md +7 -0
  24. package/skills/fix-bug/SKILL.md +4 -0
  25. package/skills/governance-protocol/SKILL.md +1 -0
  26. package/skills/init/SKILL.md +6 -0
  27. package/skills/issue-debugging/SKILL.md +3 -0
  28. package/skills/mock-detection/SKILL.md +5 -0
  29. package/skills/pipeline-templates/SKILL.md +3 -0
  30. package/skills/plan-creation/SKILL.md +10 -0
  31. package/skills/plan-to-tasks/SKILL.md +8 -0
  32. package/skills/product-ideation/SKILL.md +6 -0
  33. package/skills/session-handoff/SKILL.md +4 -0
  34. package/skills/setup-lsp/SKILL.md +6 -0
  35. package/skills/spec-drift-check/SKILL.md +8 -5
  36. package/skills/subagent-output-templating/SKILL.md +2 -0
  37. package/skills/subagent-prompting/SKILL.md +2 -0
  38. package/skills/test-audit/SKILL.md +10 -0
  39. package/skills/test-classification/SKILL.md +5 -0
  40. package/skills/test-fixture-creation/SKILL.md +6 -0
@@ -1,42 +1,50 @@
1
- {
2
- "name": "the-bulwark",
3
- "version": "1.2.1",
4
- "description": "Full-lifecycle SDLC guardrailing framework for Claude Code — from product ideation and planning through implementation, code review, and test validation. Enterprise-grade skills and agents for AI-human peer collaboration.",
5
- "author": {
6
- "name": "Ashay Kubal",
7
- "url": "https://ashaykubal.com"
8
- },
9
- "homepage": "https://github.com/QBall-Inc",
10
- "repository": "https://github.com/QBall-Inc/the-bulwark",
11
- "license": "MIT",
12
- "keywords": [
13
- "claude-code",
14
- "claude-code-plugin",
15
- "sdlc",
16
- "quality-enforcement",
17
- "code-review",
18
- "testing",
19
- "governance",
20
- "hooks",
21
- "skills",
22
- "agents",
23
- "pipeline",
24
- "ideation",
25
- "product-ideation",
26
- "product-management",
27
- "market-research",
28
- "competitive-research",
29
- "brainstorming",
30
- "brainstorm",
31
- "planning",
32
- "plan-creation",
33
- "agent-design",
34
- "skill-design",
35
- "create-skill",
36
- "create-agent",
37
- "test-audit",
38
- "test-coverage",
39
- "statusline",
40
- "agent-teams"
41
- ]
42
- }
1
+ {
2
+ "name": "the-bulwark",
3
+ "version": "1.3.0",
4
+ "description": "Full-lifecycle SDLC guardrailing framework for Claude Code — from product ideation and planning through implementation, code review, and test validation. Enterprise-grade skills and agents for AI-human peer collaboration.",
5
+ "author": {
6
+ "name": "Ashay Kubal",
7
+ "url": "https://ashaykubal.com"
8
+ },
9
+ "homepage": "https://github.com/QBall-Inc",
10
+ "repository": "https://github.com/QBall-Inc/the-bulwark",
11
+ "license": "MIT",
12
+ "keywords": [
13
+ "claude-code",
14
+ "claude-code-plugin",
15
+ "sdlc",
16
+ "quality-enforcement",
17
+ "code-review",
18
+ "testing",
19
+ "governance",
20
+ "hooks",
21
+ "skills",
22
+ "agents",
23
+ "pipeline",
24
+ "ideation",
25
+ "product-ideation",
26
+ "product-management",
27
+ "market-research",
28
+ "competitive-research",
29
+ "brainstorming",
30
+ "brainstorm",
31
+ "planning",
32
+ "plan-creation",
33
+ "agent-design",
34
+ "skill-design",
35
+ "create-skill",
36
+ "create-agent",
37
+ "test-audit",
38
+ "test-coverage",
39
+ "statusline",
40
+ "agent-teams"
41
+ ],
42
+ "userConfig": {
43
+ "enable_permission_bypass": {
44
+ "type": "boolean",
45
+ "title": "Auto-approve Bulwark bundled-asset access",
46
+ "description": "Skip permission prompts for Bulwark's own plugin scripts and bundled files (Read/Edit/Bash inside the plugin root). Writes and non-Bulwark paths are never auto-approved; path-traversal escapes are denied. Requires trusting Bulwark at install level. Default: off.",
47
+ "default": false
48
+ }
49
+ }
50
+ }
package/CHANGELOG.md CHANGED
@@ -15,6 +15,46 @@ No unreleased changes at this time.
15
15
 
16
16
  ---
17
17
 
18
+ ## [1.3.0] - 2026-06-23
19
+
20
+ Fewer prompts, sharper reviews. This release cuts permission-prompt friction for
21
+ Bulwark's own bundled assets, makes the `code-review` skill language-aware so it
22
+ only runs checks that apply to each file, and adds an opt-in hook that
23
+ auto-approves tool calls scoped to the plugin's own files.
24
+
25
+ ### Added
26
+
27
+ - **Opt-in permission-bypass hook** (`bulwark-permission-hook.sh`, PreToolUse) —
28
+ auto-approves Read/Edit/Bash calls whose targets resolve **inside the plugin's
29
+ own cache root**, so Bulwark's bundled skills and agents stop prompting for
30
+ access to their own files. Off by default and never auto-installed; opt in per
31
+ project via `bulwark-scaffold --with-permission-hook`. Path-traversal that
32
+ spoofs a plugin prefix but escapes the root is blocked, and any target outside
33
+ the plugin cache (for example `/etc/passwd` or a network `curl`) still prompts
34
+ normally. Documented as a separate, default-off hook — the always-on set
35
+ remains eight hooks.
36
+ - **`bulwark-scaffold --with-permission-hook` flag** — installs the opt-in
37
+ permission hook at project scope during scaffolding.
38
+ - **Universal per-language `code-review` recipes** across all eight Justfile
39
+ templates and the root Justfile — `typecheck-py`, `lint-py`, `validate-json` /
40
+ `validate-yaml`, and `shellcheck`. Each recipe degrades gracefully: it skips
41
+ and exits 0 when the underlying tool is absent, and propagates the tool's exit
42
+ status when present.
43
+
44
+ ### Changed
45
+
46
+ - **`code-review` skill is now language-aware** — it detects each changed file's
47
+ language and gates review sections via a Language Applicability table, so it
48
+ runs only the checks relevant to the files under review instead of assuming a
49
+ single stack.
50
+ - **`allowed-tools` declared on all 30 skills; `tools` audited on all 15
51
+ agents** — every skill now pre-authorizes exactly the tools it needs, removing
52
+ routine permission prompts during normal skill execution. (`allowed-tools`
53
+ *pre-authorizes*, it does not restrict; `disallowed-tools` remains the
54
+ restriction field.)
55
+
56
+ ---
57
+
18
58
  ## [1.2.1] - 2026-05-17
19
59
 
20
60
  Hotfix for SessionStart and Stop hooks failing with `Permission denied` on
@@ -47,52 +87,52 @@ restore correct hook execution. No project-level changes required.
47
87
 
48
88
  ## [1.2.0] - 2026-05-17
49
89
 
50
- Hardening + observability bundle covering 13+ phases of post-launch reliability,
90
+ Hardening and observability bundle covering post-launch reliability,
51
91
  governance, and tooling enhancements built between v1.1.0 and v1.2.0.
52
92
 
53
93
  ### Added
54
94
 
55
- - **`plan-to-tasks` skill** — transforms `plan-creation` output into CLEAR-compatible execution structure (`tasks.yaml` + `workpackages/`). Supports parent/child plan linkage. *(P10.5)*
56
- - **`spec-drift-check` skill** — audits work package briefs, plan docs, and memory entries for drift against current code state. Extracts claims, verifies each, emits PROCEED/STOP verdict with a structured verification log. *(P10.18)*
57
- - **`SD1` (Spec Drift) rule** in `Rules.md` — mandatory pre-WP drift check before any new or resumed implementation. *(P10.18, P10.20)*
58
- - **`init --update` mode** — guided drift remediation for stale `CLAUDE.md` / `Rules.md` sections. Batched/tabbed `AskUserQuestion` UX for ≥4 drifting sections. Parent/child anchor handling. *(P10.20, P10.24, P10.25)*
59
- - **`check-template-drift.sh` SessionStart hook** — detects when project's `CLAUDE.md` or `Rules.md` have drifted from canonical templates and surfaces them for review. *(P10.20)*
60
- - **`cleanup-review-registry.sh` SessionStart hook** — wipes stale review-accumulator state at session start so pipeline gating works across sessions. *(P10.16)*
61
- - **`.bulwark/init-marker.yaml`** — written on first `/the-bulwark:init` run; consumed by `check-template-drift.sh` to scope drift detection. *(P10.20)*
62
- - **`install-bun.sh`** — platform-aware, idempotent bun runtime installer (preparation for the evaluation framework). *(P10.11)*
63
- - **Justfile recipes for evaluation framework** — `install-bun`, `verify-bun`, `eval-skill`, `eval-grade`, `eval`. *(P10.14)*
95
+ - **`plan-to-tasks` skill** — transforms `plan-creation` output into an execution-ready structure (`tasks.yaml` + `workpackages/`). Supports parent/child plan linkage.
96
+ - **`spec-drift-check` skill** — audits work package briefs, plan docs, and memory entries for drift against current code state. Extracts claims, verifies each, emits PROCEED/STOP verdict with a structured verification log.
97
+ - **`SD1` (Spec Drift) rule** in `Rules.md` — mandatory pre-WP drift check before any new or resumed implementation.
98
+ - **`init --update` mode** — guided drift remediation for stale `CLAUDE.md` / `Rules.md` sections. Batched/tabbed `AskUserQuestion` UX for ≥4 drifting sections. Parent/child anchor handling.
99
+ - **`check-template-drift.sh` SessionStart hook** — detects when project's `CLAUDE.md` or `Rules.md` have drifted from canonical templates and surfaces them for review.
100
+ - **`cleanup-review-registry.sh` SessionStart hook** — wipes stale review-accumulator state at session start so pipeline gating works across sessions.
101
+ - **`.bulwark/init-marker.yaml`** — written on first `/the-bulwark:init` run; consumed by `check-template-drift.sh` to scope drift detection.
102
+ - **`install-bun.sh`** — platform-aware, idempotent bun runtime installer (preparation for the evaluation framework).
103
+ - **Justfile recipes for evaluation framework** — `install-bun`, `verify-bun`, `eval-skill`, `eval-grade`, `eval`.
64
104
 
65
105
  ### Changed
66
106
 
67
- - **`Stop` hook (`suggest-pipeline-stop.sh`)** — re-architected with per-file registry, file-type-aware pipeline routing, log-pattern suppression, and post-fix grace period. Reduces false-positive pipeline suggestions on doc-only or test-only changes. *(P10.12, P10.15, P10.19, P10.22)*
68
- - **`PostToolUse` matcher** widened from `Write|Edit` to `Write|Edit|MultiEdit` — quality enforcement now applies to all three mutation tools. *(P10.16)*
69
- - **`enforce-quality.sh`** — defensive `jq` fallback for malformed stdin, symlink rejection on accumulator write, atomic registry writes. *(P10.16)*
70
- - **`code-review` skill** — hook output schema validation, file-type-aware pipeline mapping, grace-window coverage aggregation. *(P10.10, P10.19, P10.22)*
71
- - **`test-audit` skill** — schema migration, grace-window coverage. *(P10.10, P10.22)*
72
- - **`plan-creation` and `bulwark-brainstorm`** — Agent Teams mode synthesis-gate fixes (CC-ALL, Work-Complete, Re-Entry gates). Resolves premature synthesis exit in dual-mode pipelines. *(P10.6)*
73
- - **`anthropic-validator`** — `SKILL.md` refactored to ≤500 lines, per-asset-type detail pushed to `references/`. Added `when_to_use` frontmatter for clearer triggering. *(P10.13)*
74
- - **`bulwark-statusline`** — uses `--no-optional-locks` to avoid `.git/index.lock` contention. *(P10.16)*
107
+ - **`Stop` hook (`suggest-pipeline-stop.sh`)** — re-architected with per-file registry, file-type-aware pipeline routing, log-pattern suppression, and post-fix grace period. Reduces false-positive pipeline suggestions on doc-only or test-only changes.
108
+ - **`PostToolUse` matcher** widened from `Write|Edit` to `Write|Edit|MultiEdit` — quality enforcement now applies to all three mutation tools.
109
+ - **`enforce-quality.sh`** — defensive `jq` fallback for malformed stdin, symlink rejection on accumulator write, atomic registry writes.
110
+ - **`code-review` skill** — hook output schema validation, file-type-aware pipeline mapping, grace-window coverage aggregation.
111
+ - **`test-audit` skill** — schema migration, grace-window coverage.
112
+ - **`plan-creation` and `bulwark-brainstorm`** — Agent Teams mode synthesis-gate fixes (CC-ALL, Work-Complete, Re-Entry gates). Resolves premature synthesis exit in dual-mode pipelines.
113
+ - **`anthropic-validator`** — `SKILL.md` refactored to ≤500 lines, per-asset-type detail pushed to `references/`. Added `when_to_use` frontmatter for clearer triggering.
114
+ - **`bulwark-statusline`** — uses `--no-optional-locks` to avoid `.git/index.lock` contention.
75
115
 
76
116
  ### Fixed
77
117
 
78
- - **`init --update`: parent/child anchor duplicate** — when both a top-level (`## Section`) and a nested (`### Subsection`) anchor drifted, the child was applied twice (once at EOF via fallback, once nested under parent). Fix suppresses child drift entries when their canonical parent is also drifting; parent's section extraction naturally brings nested children along. *(P10.25, BUG-S11-APPLY-001)*
79
- - **`init --update`: CRLF handling** — `apply-section.sh` now uses POSIX `sub(/\r$/, "")` for cross-platform CRLF stripping (gawk + mawk + BSD awk on macOS). Replaces `RS = "\r?\n"` which is gawk-only. *(P10.24)*
80
- - **`init --update`: early-exit on FALLBACK** — `apply-section.sh` no longer crashes on predecessor-lookup failure; cleanly falls through to EOF append path. *(P10.24)*
81
- - **`update.sh` and `check-template-drift.sh`: parallel CRLF risk** — same POSIX `sub(/\r$/, "")` pattern applied to all three scripts. *(P10.24)*
82
- - **`scripts/update.sh`: flag-prefix anchors** — `grep -Fxq --` end-of-options separator + herestring conversion prevent flag-shaped anchor names (`-n`, `-e`, `-E` prefixes) from being misinterpreted as command flags. *(P10.25, CR-SYN-001)*
83
- - **`bulwark-statusline`**: 3 anthropic-validator findings on frontmatter clarity. *(S119)*
118
+ - **`init --update`: parent/child anchor duplicate** — when both a top-level (`## Section`) and a nested (`### Subsection`) anchor drifted, the child was applied twice (once at EOF via fallback, once nested under parent). Fix suppresses child drift entries when their canonical parent is also drifting; parent's section extraction naturally brings nested children along.
119
+ - **`init --update`: CRLF handling** — `apply-section.sh` now uses POSIX `sub(/\r$/, "")` for cross-platform CRLF stripping (gawk + mawk + BSD awk on macOS). Replaces `RS = "\r?\n"` which is gawk-only.
120
+ - **`init --update`: early-exit on FALLBACK** — `apply-section.sh` no longer crashes on predecessor-lookup failure; cleanly falls through to EOF append path.
121
+ - **`update.sh` and `check-template-drift.sh`: parallel CRLF risk** — same POSIX `sub(/\r$/, "")` pattern applied to all three scripts.
122
+ - **`scripts/update.sh`: flag-prefix anchors** — `grep -Fxq --` end-of-options separator + herestring conversion prevent flag-shaped anchor names (`-n`, `-e`, `-E` prefixes) from being misinterpreted as command flags.
123
+ - **`bulwark-statusline`**: 3 anthropic-validator findings on frontmatter clarity.
84
124
 
85
125
  ### Security
86
126
 
87
- - **Path validation hardening** in `suggest-pipeline-stop.sh` and `cleanup-review-registry.sh` — symlink rejection on registry write, file-size caps, atomic-write guarantee. *(P10.15 self-test, S116-S117)*
88
- - **Environment variable validation** in registry-emitting hooks (`SEC-005`, `SEC-007`). *(P10.15)*
89
- - **`grep`/`sed`/`awk` end-of-options separator (`--`)** for user-controlled values, defending against flag-prefix attack vectors. *(P10.25)*
127
+ - **Path validation hardening** in `suggest-pipeline-stop.sh` and `cleanup-review-registry.sh` — symlink rejection on registry write, file-size caps, atomic-write guarantee.
128
+ - **Environment variable validation** in registry-emitting hooks.
129
+ - **`grep`/`sed`/`awk` end-of-options separator (`--`)** for user-controlled values, defending against flag-prefix attack vectors.
90
130
 
91
131
  ---
92
132
 
93
133
  ## [1.1.0] - 2026-04-21
94
134
 
95
- P10.1 — Stop hook redesign + Justfile infrastructure rollout.
135
+ Stop hook redesign + Justfile infrastructure rollout.
96
136
 
97
137
  ### Added
98
138
 
@@ -103,7 +143,7 @@ P10.1 — Stop hook redesign + Justfile infrastructure rollout.
103
143
  ### Changed
104
144
 
105
145
  - **Plugin manifest** (`.claude-plugin/plugin.json`) — adopted minimal schema; removed redundant `skills`/`agents`/`hooks` arrays now that Claude Code auto-discovers them. Resolves duplicate-hooks loading error reported by early users.
106
- - **`Stop` hook output** — removed invalid `hookSpecificOutput` field that violated the Claude Code hook JSON schema. *(P10.10 root-cause-of-symptom)*
146
+ - **`Stop` hook output** — removed invalid `hookSpecificOutput` field that violated the Claude Code hook JSON schema.
107
147
 
108
148
  ### Fixed
109
149
 
@@ -144,7 +184,9 @@ Initial public release.
144
184
 
145
185
  ---
146
186
 
147
- [Unreleased]: https://github.com/QBall-Inc/the-bulwark/compare/v1.2.0...HEAD
187
+ [Unreleased]: https://github.com/QBall-Inc/the-bulwark/compare/v1.3.0...HEAD
188
+ [1.3.0]: https://github.com/QBall-Inc/the-bulwark/compare/v1.2.1...v1.3.0
189
+ [1.2.1]: https://github.com/QBall-Inc/the-bulwark/compare/v1.2.0...v1.2.1
148
190
  [1.2.0]: https://github.com/QBall-Inc/the-bulwark/compare/v1.1.0...v1.2.0
149
191
  [1.1.0]: https://github.com/QBall-Inc/the-bulwark/compare/v1.0.1...v1.1.0
150
192
  [1.0.1]: https://github.com/QBall-Inc/the-bulwark/compare/v1.0.0...v1.0.1
@@ -0,0 +1,52 @@
1
+ # Contributing to The Bulwark
2
+
3
+ Thanks for your interest in improving The Bulwark. Issues and pull requests are both welcome — this guide explains how contributions flow, because the repository model is a little different from a typical single-repo project.
4
+
5
+ ## How this repository works
6
+
7
+ This public repository (`QBall-Inc/the-bulwark`) is a **mirror**. Active development happens in a private repository, and the user-facing plugin assets are synced here. That means:
8
+
9
+ - The code you see here is the published plugin surface, not the full development history.
10
+ - Changes merged here are **ported back** into the private repo by the maintainer, which then re-syncs. This keeps the two repositories from diverging.
11
+
12
+ ## Opening an issue
13
+
14
+ Issues are open to everyone and are the fastest way to help. Please use the structured templates:
15
+
16
+ - **Bug report** — include reproduction steps, expected vs actual behavior, your plugin version, Claude Code version, OS/platform (WSL / macOS / Linux), and the relevant hook or skill.
17
+ - **Feature request** — describe the problem, your proposed solution, and any alternatives you considered.
18
+
19
+ [Open an issue →](https://github.com/QBall-Inc/the-bulwark/issues/new/choose)
20
+
21
+ ## Submitting a pull request
22
+
23
+ PRs are **accepted on this public repository.** Here's the flow:
24
+
25
+ 1. Fork the repo and create a branch from `main`.
26
+ 2. Make your change. Keep it focused — one logical change per PR.
27
+ 3. If you touch a Claude Code asset (skill, agent, hook, plugin manifest), make sure it still follows the [conventions](docs/reference/conventions.md) and validates against Anthropic's standards.
28
+ 4. Open the PR against `main` with a clear description of what changed and why.
29
+
30
+ ### What happens after you open a PR
31
+
32
+ - The maintainer reviews the PR here on the public repo.
33
+ - When it's accepted, the change is **merged here and then ported into the private dev repo**, which becomes the source of truth for the next sync. Your contribution is preserved and you are credited.
34
+ - Because syncing flows private → public, the porting step is **mandatory** — without it, a later sync would overwrite a merged public PR. The maintainer owns this step; you don't need to do anything beyond opening the PR.
35
+
36
+ > **Note for the maintainer:** a merged public PR lives only on the public repo until it is ported into the private repo. Port it *before* the next `sync-to-public.sh` run, or the sync will clobber it.
37
+
38
+ ## Development conventions
39
+
40
+ If you're proposing a code or asset change, it's worth knowing the standards the project enforces on itself:
41
+
42
+ - **[Conventions](docs/reference/conventions.md)** — the CS / T / V / ID rules (coding standards, testing, verification, issue debugging).
43
+ - **[How it works](docs/guides/how-it-works.md)** and **[architecture.md](docs/architecture.md)** — the design model.
44
+ - Markdown and shell files use **LF line endings** only.
45
+
46
+ ## Code of conduct
47
+
48
+ Please be respectful and constructive in issues and PRs. We aim to keep this a welcoming project for contributors of all backgrounds.
49
+
50
+ ## Questions
51
+
52
+ If something here is unclear, [open an issue](https://github.com/QBall-Inc/the-bulwark/issues) and ask — clarifying questions are welcome.