fix: instantiate knot-rider from the RSR template - #17
Merged
Conversation
knot-rider was scaffolded from rsr-template-repo but never instantiated:
{{PLACEHOLDER}} tokens survived throughout, including in the .zig sources,
which meant the Zig FFI seam genuinely did not parse.
- Substitute RSR identity placeholders ({{PROJECT_NAME}}, {{OWNER}}, {{REPO}},
{{AUTHOR}}, {{FORGE}}, etc.) with real values across ~80 files, leaving
intentional generic scaffolding (docs-template/, ADR templates, K9 example
configs, native Justfile {{recipe}} interpolation) untouched.
- Fix the .github/settings.yml probot landmine: an unsubstituted
name: "{{REPO}}" would have made the app try to rename the repo to the
literal string "{{REPO}}" on the next push to main.
- Fix src/interface/ffi/src/main.zig: {{project}}_* -> knot_rider_*. This
alone doesn't make it build under Zig 0.16: also fixed `opaque` types
carrying fields (no longer legal) and callconv(.C) -> callconv(.c).
Rewrote build.zig (previously inert scaffolding with zero real targets)
to actually build main.zig as a static lib and wire `zig build test` to
the real test suites. `zig fmt --check`, `zig build`, and `zig build test`
all now pass for real (4/4 tests).
- .machine_readable/6a2/{CLADE,ECOSYSTEM,STATE}.a2ml still described
rsr-template-repo's own identity/purpose/95%-complete maturity claim
(not a {{}} token — hardcoded wrong content). Fixed the identity/purpose/
state fields feeding the CLAUDE.md arrival-pack generator, then
regenerated CLAUDE.md for real via `just claude-md` instead of hand-
editing the generated region.
- Rewired Justfile TODO/echo stubs to real commands backed by this repo's
actual toolchain (zig build/test/fmt, idris2 --typecheck abi.ipkg, tests/
e2e.sh, tests/aspect_tests.sh); deleted recipes with nothing to back them
(run, run-verbose) instead of leaving fake "success" stubs.
- Fixed two real false positives this surfaced in tests/aspect_tests.sh
(doc prose describing banned patterns flagged as violations; build-cache
files scanned for SPDX headers) so `just test-all` / `just quality` are
genuinely green, not just newly-wired-but-red.
- Removed obsolete template machinery: scripts/validate-template.sh,
tests/e2e/template_instantiation_test.sh, benches/template_bench.sh,
.machine_readable/ai/PLACEHOLDERS.adoc. No workflow referenced them.
- Rewrote README/EXPLAINME/AFFIRMATION honestly: this project's specific
technical purpose is not documented anywhere in this repo or the wider
hyperpolymath estate registry, beyond the name and GitHub's Knight-Rider-
intro-pun description. Not invented here.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
hyperpolymath
marked this pull request as ready for review
July 27, 2026 18:25
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Summary
knot-riderwas scaffolded fromrsr-template-repobut never instantiated —{{PLACEHOLDER}}tokens survived throughout, including in the.zigsources, so the Zig FFI seam genuinely did not parse. This PR cures the instantiation for real.{{PROJECT_NAME}},{{OWNER}},{{REPO}},{{AUTHOR}},{{FORGE}},{{LICENSE}}, etc.) — real values used throughout, intentional generic scaffolding (docs-template/, ADR templates, K9 example configs, native Justfile{{recipe}}interpolation) left untouched..github/settings.ymllandmine fixed: an unsubstitutedname: "{{REPO}}"under the probot/settings config would have made the app try to rename the repo to the literal string{{REPO}}on the next push tomain.{{project}}_*→knot_rider_*, plus two real Zig 0.16 incompatibilities fixed along the way (opaquetypes can no longer carry fields;callconv(.C)→callconv(.c)).build.zigwas previously inert scaffolding with zero real build targets — rewrote it to actually compilemain.zigas a static library and wirezig build testto the real test suites.zig fmt --check,zig build, andzig build testall pass (4/4 tests)..machine_readable/6a2/{CLADE,ECOSYSTEM,STATE}.a2mlstill describedrsr-template-repo's own identity/purpose/"95% complete, production maturity" claim — hardcoded wrong content, not a{{}}token. Fixed the fields that feed theCLAUDE.mdarrival-pack generator, then regeneratedCLAUDE.mdfor real viajust claude-mdrather than hand-editing the generated region.build/test/fmt/fmt-check→ realzig build/zig build test/zig fmt;lint→idris2 --typecheck abi.ipkg;e2e/aspect→bash tests/e2e.sh/bash tests/aspect_tests.sh;deps→ checks the Zig toolchain. Deletedrun/run-verbose/bench/readinessrecipes rather than leaveecho "..."fake-pass stubs — this repo is a C-ABI library with no application entry point and no bench/readiness suite exists.tests/aspect_tests.shthat the newly-wiredaspectrecipe surfaced: documentation prose describing banned patterns (sorry,Admitted) was being flagged as a violation, and Zig build-cache files were being scanned for SPDX headers.just test-all/just qualityare genuinely green now, not just newly-wired-but-red.scripts/validate-template.sh,tests/e2e/template_instantiation_test.sh,benches/template_bench.sh,.machine_readable/ai/PLACEHOLDERS.adoc. No workflow referenced any of them (re-verified).This project's purpose remains undocumented
This is deliberate, not an oversight.
knot-rider's specific technical purpose is not documented anywhere in this repository or the wider hyperpolymath estate registry (checked:reposystemtool registry,verisimdb-data,gitbot-fleet, estate memory). The only repo-specific content that exists is GitHub's own description, a knowing pun on the Knight Rider intro monologue:That's wordplay, not a spec. README.adoc says this plainly rather than inventing a product story.
Known, out-of-scope findings (not fixed here)
rsr-template-repo(not a{{}}placeholder, so outside this PR's defined scope) still appears as leftover self-referential text in ~40 files under.machine_readable/contractiles/,docs/onboarding/,docs/status/,.machine_readable/coaptation/, etc. I fixed the highest-impact instances (the ones feedingCLAUDE.md, the Justfile's user-facingdoctor/touroutput, and de-duplicated.machine_readable/contractiles/Justfileback into a hardlink of the root Justfile per its own dust-check). A full sweep of this second bug class would roughly double the size of this change and is a reasonable follow-up.docs/status/TEST-NEEDS.adocdescribesrsr-template-repo's own historical test-suite development (not knot-rider's) — left as-is, flagged as stale.idris2 --typecheck abi.ipkgwas verified to pass in this environment (exit 0, warnings only), but this wasn't part of the original ask and toolchain availability may differ elsewhere.Test plan
zig fmt --check src/interface/ffi— exit 0cd src/interface/ffi && zig build— exit 0cd src/interface/ffi && zig build test— exit 0, 4/4 tests passjust quality(fmt-check + lint + test) — exit 0just test-all(test + e2e + aspect) — exit 0just claude-md && just validate-claude-md— in syncpython3 -c "import yaml; yaml.safe_load(...)".github/workflows/*.ymlreferences to the deleted template-machinery scripts — none found🤖 Generated with Claude Code