41 lines
1.4 KiB
Markdown
41 lines
1.4 KiB
Markdown
# Bible
|
|
|
|
Shared engineering rules library for Go web projects.
|
|
|
|
Add as a git submodule to any project — agents (Claude, Codex) will read the rules automatically.
|
|
|
|
Agents start at `AGENT-BOOTSTRAP.md` — it defines the read path, always-on contracts,
|
|
and the task router. Nothing in this README duplicates it.
|
|
|
|
## Usage
|
|
|
|
```bash
|
|
# Add to a project
|
|
git submodule add https://git.mchus.pro/mchus/bible.git bible
|
|
|
|
# Update to latest rules
|
|
git submodule update --remote bible
|
|
```
|
|
|
|
## Structure
|
|
|
|
```
|
|
AGENT-BOOTSTRAP.md — first file agents should read; contains the full contract router
|
|
rules/patterns/<topic>/ — short contract.md and optional README.md
|
|
<subtopic>/ — atomic contract and its examples
|
|
examples/<name>/ — optional multi-component demonstration
|
|
rules/ai/AGENT.template.md — template for new projects; copy as both CLAUDE.md and AGENTS.md
|
|
scripts/lint.sh — consistency checks (router coverage, broken links)
|
|
```
|
|
|
|
Run `sh scripts/lint.sh` after changes (requires Python 3 for local-link and nested-contract checks).
|
|
|
|
## Project Setup
|
|
|
|
Each project needs:
|
|
- `bible/` — this submodule
|
|
- `bible-local/` — project-specific architecture (data model, API, ADL)
|
|
- `CLAUDE.md` + `AGENTS.md` — copies of `rules/ai/AGENT.template.md` pointing agents to the bootstrap
|
|
|
|
See `rules/patterns/go-project-bible/contract.md` for what goes in `bible-local/`.
|