Skip to content

chore(hooks): version-controlled pre-commit + SPDX split by file-type#48

Merged
hyperpolymath merged 1 commit into
mainfrom
chore/canonical-pre-commit-hook
Jun 29, 2026
Merged

chore(hooks): version-controlled pre-commit + SPDX split by file-type#48
hyperpolymath merged 1 commit into
mainfrom
chore/canonical-pre-commit-hook

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

Ports the documented estate hook fix here and makes hooks reproducible.

What

  • Committed, installable hook: hooks/pre-commit + hooks/install.sh (sets core.hooksPath=hooks). Fixes the "hooks not reproducible across clones" finding — the old enforcer lived only in un-versioned .git/hooks/.
  • SPDX split by file-type (LICENCE-POLICY Rule 1): prose docs (.md/.adoc) → CC-BY-SA-4.0, code/config → MPL-2.0. The old hook demanded MPL on every doc, contradicting the estate docs-licence policy and rejecting correctly CC-BY-SA-licensed docs.
  • Owner-string check kept strict on all files (deliberate LLM-edit diagnostic).
  • No-C / SNIFs / Idris-ABI policies preserved unchanged.

Verified

  • CC-BY-SA doc + owner → ✓ accepted
  • MPL-only doc → ✓ correctly rejected (docs must be CC-BY-SA now)
  • MPL code + owner → ✓ accepted

Installed locally (core.hooksPath=hooks).

🤖 Generated with Claude Code

Replaces the un-versioned .git/hooks/pre-commit with a committed, installable
hook (hooks/pre-commit + hooks/install.sh sets core.hooksPath=hooks), fixing
the 'hooks not reproducible across clones' gap.

Licence fix (LICENCE-POLICY Rule 1): SPDX expectation now splits by file-type
— prose docs (.md/.adoc) expect CC-BY-SA-4.0, code/config expect MPL-2.0 —
so the hook stops rejecting correctly CC-BY-SA-licensed docs. Owner-string
check kept strict on all (deliberate LLM-edit diagnostic). No-C / SNIFs /
Idris-ABI policies preserved unchanged.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@hyperpolymath hyperpolymath merged commit ac1392a into main Jun 29, 2026
22 of 23 checks passed
@hyperpolymath hyperpolymath deleted the chore/canonical-pre-commit-hook branch June 29, 2026 11:34
hyperpolymath added a commit that referenced this pull request Jun 29, 2026
Finishes the deferred doc work (you authorised the header edits).

## Reference fixes (post-rename)
- `ai/README.adoc`, `AI-CONVENTIONS.adoc`, `bot_directives/README.adoc`:
stale paths → new canon (`descriptiles/`, `descriptiles/anchors/`,
`bot_directives/`), incl. fixing pre-existing root-vs-`6a2` path bugs.
- `bot_directives/README.adoc`: title `Agent Instructions` → `Bot
Directives`; relationship section reconciled (this dir *is* the former
`agent_instructions`).

## Factual fixes
- `TEST-NEEDS.md`: CI workflow count **21 → 14** (actual).
- `ROADMAP.adoc`: v1.0.0 marked **shipped 2026-05-29** (per CHANGELOG);
Current Status updated.

## Headers
Added/normalised `CC-BY-SA-4.0` + canonical owner-string on every edited
doc — dropped the `(hyperpolymath)`/year owner-string variant so they
pass the file-type-split pre-commit hook (#48). Manually validated
against that hook's logic.

Depends-on: #48 (the hook) for the headers to be enforced. README dedup
was already resolved (no `README.adoc`; `README.md` is canonical
CC-BY-SA).

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant