@techgoblin/gobstack 0.0.0-stage → 0.4.4-beta.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 +351 -0
- package/LICENSE +21 -0
- package/README.md +163 -2
- package/VERSION +1 -0
- package/adapters/_template/adapter.tsv +16 -0
- package/adapters/_template/detect.sh +10 -0
- package/adapters/_template/emit.sh +5 -0
- package/adapters/_template/verify.sh +4 -0
- package/adapters/claude/adapter.tsv +8 -0
- package/adapters/claude/detect.sh +8 -0
- package/adapters/claude/verify.sh +47 -0
- package/adapters/codex/adapter.tsv +12 -0
- package/adapters/codex/detect.sh +9 -0
- package/adapters/codex/verify.sh +45 -0
- package/adapters/copilot/adapter.tsv +10 -0
- package/adapters/copilot/detect.sh +8 -0
- package/adapters/copilot/verify.sh +45 -0
- package/adapters/cursor/adapter.tsv +11 -0
- package/adapters/cursor/detect.sh +10 -0
- package/adapters/cursor/verify.sh +45 -0
- package/adapters/gemini/adapter.tsv +15 -0
- package/adapters/gemini/detect.sh +11 -0
- package/adapters/gemini/verify.sh +49 -0
- package/adapters/hermes/adapter.tsv +9 -0
- package/adapters/hermes/detect.sh +8 -0
- package/adapters/hermes/verify.sh +27 -0
- package/adapters/opencode/adapter.tsv +14 -0
- package/adapters/opencode/detect.sh +9 -0
- package/adapters/opencode/verify.sh +45 -0
- package/automations/README.md +53 -0
- package/automations/bugreporter-intake.sh +145 -0
- package/automations/drift-audit.sh +139 -0
- package/automations/report.schema.tsv +10 -0
- package/bans/README.md +82 -0
- package/bans/grep-ban.sh +84 -0
- package/bans/layer-check.sh +57 -0
- package/bin/goblin +119 -0
- package/bin/goblin-audit +145 -0
- package/bin/goblin-bans +178 -0
- package/bin/goblin-doctor +233 -0
- package/bin/goblin-emit +482 -0
- package/bin/goblin-init +519 -0
- package/bin/goblin-install +720 -0
- package/bin/goblin-lib.sh +289 -0
- package/bin/goblin-model +105 -0
- package/bin/goblin-upgrade +572 -0
- package/bin/goblin-verify +2798 -0
- package/bin/goblin.js +48 -0
- package/docs/ADOPTION.md +168 -0
- package/docs/CI.md +187 -0
- package/docs/CONTRACTS.md +197 -0
- package/docs/DESIGN.md +92 -0
- package/docs/ENFORCEMENT.md +225 -0
- package/docs/FLOWS.md +164 -0
- package/docs/GUARDRAILS.md +126 -0
- package/docs/GUIDE.md +610 -0
- package/docs/INTEGRATION.md +92 -0
- package/docs/LIMITS.md +591 -0
- package/docs/LOOP.md +165 -0
- package/docs/RE-PLAYBOOK.md +183 -0
- package/docs/RISKS.md +70 -0
- package/docs/ROLES.md +105 -0
- package/manifest/bans.tsv +9 -0
- package/manifest/classes.tsv +61 -0
- package/manifest/enforcement.tsv +88 -0
- package/manifest/glossary.tsv +25 -0
- package/manifest/playbooks.tsv +16 -0
- package/package.json +36 -4
- package/presets/A-shipped-software.yaml +48 -0
- package/presets/B-service-config.yaml +40 -0
- package/presets/C-game.yaml +38 -0
- package/presets/D-knowledge.yaml +41 -0
- package/presets/E-fleet-config.yaml +42 -0
- package/presets/F-electron.yaml +67 -0
- package/roles.yaml +54 -0
- package/skills/goblin-bootstrap/SKILL.md +51 -0
- package/skills/goblin-bugfix/SKILL.md +26 -0
- package/skills/goblin-bugreporter/SKILL.md +52 -0
- package/skills/goblin-drift-audit/SKILL.md +43 -0
- package/skills/goblin-eval/SKILL.md +68 -0
- package/skills/goblin-feature/SKILL.md +26 -0
- package/skills/goblin-feature-map/SKILL.md +140 -0
- package/skills/goblin-handoff/SKILL.md +28 -0
- package/skills/goblin-investigation/SKILL.md +26 -0
- package/skills/goblin-judge/SKILL.md +74 -0
- package/skills/goblin-loop/SKILL.md +88 -0
- package/skills/goblin-mode/SKILL.md +70 -0
- package/skills/goblin-overnight/SKILL.md +42 -0
- package/skills/goblin-pr-gate/SKILL.md +42 -0
- package/skills/goblin-re-mobile/SKILL.md +51 -0
- package/skills/goblin-refactor/SKILL.md +23 -0
- package/skills/goblin-sweep/SKILL.md +23 -0
- package/skills/goblin-tdd-repro/SKILL.md +27 -0
- package/skills/goblin-verify-author/SKILL.md +50 -0
- package/skills/practice/SKILL.md +37 -0
- package/templates/AGENTS.md.tmpl +23 -0
- package/templates/HANDOFF.md.tmpl +43 -0
- package/templates/SPEC.md.tmpl +34 -0
- package/templates/audit-waiver.tsv.tmpl +10 -0
- package/templates/boundary-waivers.tmpl +8 -0
- package/templates/checks/assert.mjs.tmpl +60 -0
- package/templates/checks/gate.sh.tmpl +29 -0
- package/templates/ci/goblin-gate.yml.tmpl +46 -0
- package/templates/goblin.yaml.tmpl +138 -0
- package/templates/install-hooks.allowlist.tmpl +9 -0
- package/templates/loop/decisions.tsv.tmpl +1 -0
- package/templates/loop/predicate.tmpl +16 -0
- package/templates/report.yaml.tmpl +16 -0
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
# .goblin/goblin.yaml — the project config. Generated once by goblin-install, then YOURS.
|
|
2
|
+
# It is never overwritten after the first install: edit it in place.
|
|
3
|
+
#
|
|
4
|
+
# Format: a flat, line-oriented YAML subset, parsed by .goblin/bin/goblin-lib.sh. No YAML
|
|
5
|
+
# library, no network, no npm. Keep one key per line and keep comments on their own line.
|
|
6
|
+
|
|
7
|
+
# Which class this project is (A|B|C|D|E). Selects the required parts (manifest/classes.tsv).
|
|
8
|
+
class: {{CLASS}}
|
|
9
|
+
|
|
10
|
+
# The default branch, DECLARED, never assumed. A preset that assumes the wrong branch
|
|
11
|
+
# silently skips a repo.
|
|
12
|
+
branch: {{BRANCH}}
|
|
13
|
+
|
|
14
|
+
# The model mapping — the ONE install-time machine input. goblin-stack READS this file and
|
|
15
|
+
# never writes it. Absent on another machine: every model-dependent check reports advisory.
|
|
16
|
+
models_file: {{MODELS_FILE}}
|
|
17
|
+
|
|
18
|
+
# The global engine (optional, W1). Where the ENGINE tier lives on this machine — an
|
|
19
|
+
# absolute path or ~/-prefixed. Absent by default: a fresh per-repo install is
|
|
20
|
+
# byte-compatible with today, and verify resolves its engine exactly as it always did.
|
|
21
|
+
# Declared but unusable (relative path, missing directory, no manifest inside) is
|
|
22
|
+
# verify exit 2 with NO fallback — a repo must not be judged by an engine it did not
|
|
23
|
+
# declare. Authored by hand (or by `goblin upgrade`, W3); goblin-install never writes it.
|
|
24
|
+
# engine_dir: ~/.goblin/engine
|
|
25
|
+
|
|
26
|
+
# The referenced standard (optional). goblin-stack carries no copy of it; it pins its hash.
|
|
27
|
+
practice: {{PRACTICE}}
|
|
28
|
+
practice_sha256: {{PRACTICE_SHA}}
|
|
29
|
+
|
|
30
|
+
# The commit identity this repo expects (CM-01).
|
|
31
|
+
owner_email: {{OWNER_EMAIL}}
|
|
32
|
+
|
|
33
|
+
# archive: true -> verify requires no HANDOFF and no gates, and says so.
|
|
34
|
+
archive: {{ARCHIVE}}
|
|
35
|
+
|
|
36
|
+
# Uncommitted entries allowed at verify time (CM-03). 0 means commit as you go.
|
|
37
|
+
max_dirty: {{MAX_DIRTY}}
|
|
38
|
+
|
|
39
|
+
# Unenforceable rules are counted; this is the cap that stops the matrix decaying into prose.
|
|
40
|
+
advisory_ceiling: {{ADVISORY_CEILING}}
|
|
41
|
+
|
|
42
|
+
# Whether this class requires a client-visible surface to be secret-free (SC-01..SC-09 read the
|
|
43
|
+
# `security:` block below). Declared, never inferred: a stack-specific rule guessed from the
|
|
44
|
+
# files on disk is how a matrix starts lying.
|
|
45
|
+
security:
|
|
46
|
+
gitignore_family: {{SEC_GITIGNORE_FAMILY}}
|
|
47
|
+
build_output: {{SEC_BUILD_OUTPUT}}
|
|
48
|
+
audit_cmd: {{SEC_AUDIT_CMD}}
|
|
49
|
+
audit_max_age_days: {{SEC_AUDIT_MAX_AGE}}
|
|
50
|
+
waiver_max_age_days: {{SEC_WAIVER_MAX_AGE}}
|
|
51
|
+
write_routes: {{SEC_WRITE_ROUTES}}
|
|
52
|
+
|
|
53
|
+
# The performance budget (PF-01). The NUMBER lives in `ratchet:` above — this block only names
|
|
54
|
+
# the commit it was measured on, so "I raised the ceiling" cannot silently become "I never
|
|
55
|
+
# measured again". An empty baseline_commit means "not measured yet" and PF-01 skips with that
|
|
56
|
+
# reason; a baseline_commit that does not resolve to an ancestor of HEAD is a RED.
|
|
57
|
+
perf:
|
|
58
|
+
metric: {{PERF_METRIC}}
|
|
59
|
+
cmd: {{PERF_CMD}}
|
|
60
|
+
baseline_commit: {{PERF_BASELINE_COMMIT}}
|
|
61
|
+
baseline_value: {{PERF_BASELINE_VALUE}}
|
|
62
|
+
measured: {{PERF_MEASURED}}
|
|
63
|
+
host_gate: {{PERF_HOST_GATE}}
|
|
64
|
+
|
|
65
|
+
# Where the asserting harnesses live.
|
|
66
|
+
harness_dir: {{HARNESS_DIR}}
|
|
67
|
+
|
|
68
|
+
# Whether this class scaffolds that directory. A declared harness_dir that is absent FAILS
|
|
69
|
+
# (HS-01) when this is yes; a class that ships no harness dir skips with a reason.
|
|
70
|
+
scaffold_checks: {{SCAFFOLD_CHECKS}}
|
|
71
|
+
|
|
72
|
+
# The feature map (P6's inventory, authored by skills/goblin-feature-map).
|
|
73
|
+
# feature_map: the map's README, relative to this repo. EMPTY means "no map declared yet" and
|
|
74
|
+
# makes FM-01/FM-02 SKIP with that reason - a fresh install has no map and must not be born RED.
|
|
75
|
+
# source_root: entry paths in the map resolve against this.
|
|
76
|
+
# verify_doctor: the command the map's own instructions say to run. EMPTY -> VA-01 SKIPs.
|
|
77
|
+
feature_map: {{FEATURE_MAP}}
|
|
78
|
+
source_root: {{SOURCE_ROOT}}
|
|
79
|
+
verify_doctor: {{VERIFY_DOCTOR}}
|
|
80
|
+
|
|
81
|
+
# The reference corpus (P15). `reference_manifest:` names the manifest RC-01/RC-02/RC-04 read: a
|
|
82
|
+
# hash-only record of the quarantined corpus, never the corpus itself. EMPTY means "no reference
|
|
83
|
+
# corpus is declared" and makes RC-01, RC-02 and RC-04 SKIP with that reason - a repo with no
|
|
84
|
+
# corpus must not be born RED. A key that IS set but names a missing or unparseable file is a
|
|
85
|
+
# FAIL, never a skip, so losing the manifest cannot read as "no corpus". RC-01 also reads the
|
|
86
|
+
# `security: build_output:` list above: a file there whose sha256 appears in an entry fails the
|
|
87
|
+
# build.
|
|
88
|
+
# `quarantine_root:` is the quarantine directory the procedure extracts into (outside this repo).
|
|
89
|
+
# No row reads it; it is declared so the procedure has a machine-readable anchor instead of a path
|
|
90
|
+
# in prose.
|
|
91
|
+
reference_manifest: {{REFERENCE_MANIFEST}}
|
|
92
|
+
quarantine_root: {{QUARANTINE_ROOT}}
|
|
93
|
+
|
|
94
|
+
# The loop ceiling (G2, LP-03). The most turns ONE loop record may declare in its budget, so a
|
|
95
|
+
# runaway loop cannot buy itself unlimited iterations. 20 is the engine's own default for a
|
|
96
|
+
# kanban goal loop, measured; a ceiling that does not match the engine's default is a number
|
|
97
|
+
# someone made up. It bounds one loop's turns, never how many loops exist.
|
|
98
|
+
loop_max_turns_ceiling: {{LOOP_MAX_TURNS}}
|
|
99
|
+
|
|
100
|
+
# The gate set. DECLARED, never inferred from the stack. Replace the default below with the
|
|
101
|
+
# real commands for this project; each must exit 0. The whole block is rendered by one
|
|
102
|
+
# placeholder (a class may declare a second gate - A's TODO ceiling), so a second, empty
|
|
103
|
+
# placeholder line below it leaked an unsubstituted token into every class's installed config
|
|
104
|
+
# and nothing rendered it (Z1-3).
|
|
105
|
+
gates:
|
|
106
|
+
{{GATES}}
|
|
107
|
+
|
|
108
|
+
# A count that must not rise, with its ceiling. The ceiling was measured at install time.
|
|
109
|
+
ratchet:
|
|
110
|
+
name: {{RATCHET_NAME}}
|
|
111
|
+
cmd: {{RATCHET_CMD}}
|
|
112
|
+
ceiling: {{RATCHET_CEILING}}
|
|
113
|
+
|
|
114
|
+
# Paths a probe must never write (DS-01/DS-02 hash them around every gate run).
|
|
115
|
+
runtime_data:
|
|
116
|
+
{{RUNTIME_DATA}}
|
|
117
|
+
|
|
118
|
+
# The ban list (G5). Which bans this project turns on; an unlisted ban SKIPs with a reason.
|
|
119
|
+
# A ban's mechanism lives in .goblin/manifest/bans.tsv; the engine is .goblin/bin/goblin-bans.
|
|
120
|
+
bans: [{{BANS}}]
|
|
121
|
+
|
|
122
|
+
# Narrow, explicit, reviewed exceptions (Dune rule 5): "- <ban id> <path prefix>".
|
|
123
|
+
bans_exempt:
|
|
124
|
+
{{BANS_EXEMPT}}
|
|
125
|
+
|
|
126
|
+
# What BN-05 reads: "<from> <to>" layer pairs. Empty -> BN-05 SKIPs with a reason.
|
|
127
|
+
layers:
|
|
128
|
+
{{LAYERS}}
|
|
129
|
+
|
|
130
|
+
# How a harness proves RED on the pre-change tree (HS-02). Set commit: to the pinned
|
|
131
|
+
# pre-change SHA once the round it guards has landed; until then HS-02 is skipped with a reason.
|
|
132
|
+
replay:
|
|
133
|
+
env: {{REPLAY_ENV}}
|
|
134
|
+
cmd: {{REPLAY_CMD}}
|
|
135
|
+
commit: ""
|
|
136
|
+
|
|
137
|
+
# Parts recorded as opt-out. Their required checks report SKIP (opt-out) rather than passing.
|
|
138
|
+
disabled: [{{DISABLED}}]
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# .goblin/install-hooks.allowlist — dependencies whose install-time script is accepted (SC-08).
|
|
2
|
+
#
|
|
3
|
+
# One package name per line. SC-08 enumerates package-lock.json for "hasInstallScript": true and
|
|
4
|
+
# requires every one of them to appear here. An install hook is arbitrary code that runs on every
|
|
5
|
+
# `npm ci` (and on every CI job), so the list is short and each entry is a decision, not a default.
|
|
6
|
+
#
|
|
7
|
+
# example:
|
|
8
|
+
# esbuild
|
|
9
|
+
# sharp
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
ts phase decision why evidence result
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# .goblin/loop/predicate — the loop's exit condition. Copy this file to that path and edit it.
|
|
2
|
+
#
|
|
3
|
+
# ONE command. Exits 0 == the loop is finished. Comments are allowed here; the command is the
|
|
4
|
+
# single non-blank, non-comment line (LP-01 checks exactly that).
|
|
5
|
+
#
|
|
6
|
+
# A duration is NOT a finish condition, and neither is a description of one.
|
|
7
|
+
# Run it once BEFORE iteration 1 and record the result in .goblin/loop/first-run as
|
|
8
|
+
# "exit=<n> ts=<ISO8601>": the run-once rule is how you know the command is runnable and
|
|
9
|
+
# currently red, which is what makes a later green mean anything.
|
|
10
|
+
# Then pin it: sha256sum .goblin/loop/predicate | cut -d' ' -f1 > .goblin/loop/predicate.sha256
|
|
11
|
+
# Never edit the predicate mid-loop — archive it under .goblin/loop/closed-<date>/ together with
|
|
12
|
+
# the pin it was closed under, then open a new loop whose predicate.sha256 names the archived
|
|
13
|
+
# digest on a `previous: <digest>` line (LP-02: a silent relaxation FAILs; the chain is the record).
|
|
14
|
+
#
|
|
15
|
+
# Replace the line below with the real condition. Example shape only:
|
|
16
|
+
node tools/check-cycles.mjs
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# reports/<slug>/report.yaml — one report, one file, one schema.
|
|
2
|
+
#
|
|
3
|
+
# A report is a file with a schema, not prose in a card body: prose invites the agent to fill
|
|
4
|
+
# the gaps by guessing, and a guess at intake poisons everything downstream. The validator is
|
|
5
|
+
# `automations/bugreporter-intake.sh`; the schema it enforces is `automations/report.schema.tsv`.
|
|
6
|
+
|
|
7
|
+
repo: # REQUIRED. path or remote of the repository the defect is in
|
|
8
|
+
symptom: # REQUIRED. one line, observable
|
|
9
|
+
expected: # REQUIRED. one line
|
|
10
|
+
observed: # REQUIRED. one line
|
|
11
|
+
repro_steps: # REQUIRED. ordered list, one item per line, 4-space indented
|
|
12
|
+
-
|
|
13
|
+
revision: # REQUIRED. a commit that exists in that repository
|
|
14
|
+
dedup_key: # REQUIRED. bug:<repo>:<sha256(normalised symptom)[:12]> - content only
|
|
15
|
+
environment: # optional. platform/version; absent is recorded as unknown, never guessed
|
|
16
|
+
evidence: # optional. paths to captures; evidence for a human, never harness proof
|