Summary
Add a pre-commit hook that runs task sync-module automatically when canonical skill or command files change, so contributors don't have to remember to sync manually.
Context
PR #126 introduced module/ as the lola-distributable copy of canonical sources in skills/ and .opencode/commands/. It includes:
task sync-module — manual sync step
task check-module-sync — manual drift check
- A CI job in
ci_local.yml that gates PRs on drift detection
The CI job catches drift, but contributors still have to manually run task sync-module before committing. A pre-commit hook would automate this.
Proposed Change
Add a local hook to .pre-commit-config.yaml:
- repo: local
hooks:
- id: sync-module
name: Sync module copies
entry: task sync-module
language: system
files: ^(skills/|\.opencode/commands/comply-)
pass_filenames: false
This triggers only when canonical source files are staged, keeping pre-commit fast for unrelated changes.
Prerequisites
- Requires task (Taskfile runner) installed locally
- Requires contributors to set up pre-commit hooks (pre-commit install)
Acceptance Criteria
Summary
Add a pre-commit hook that runs
task sync-moduleautomatically when canonical skill or command files change, so contributors don't have to remember to sync manually.Context
PR #126 introduced
module/as the lola-distributable copy of canonical sources inskills/and.opencode/commands/. It includes:task sync-module— manual sync steptask check-module-sync— manual drift checkci_local.ymlthat gates PRs on drift detectionThe CI job catches drift, but contributors still have to manually run
task sync-modulebefore committing. A pre-commit hook would automate this.Proposed Change
Add a local hook to
.pre-commit-config.yaml:This triggers only when canonical source files are staged, keeping pre-commit fast for unrelated changes.
Prerequisites
Acceptance Criteria
## Related