Skill Tracer
Skills › BMAD Method › bmad-project-context › template.md

template.md

55 lines · skills/bmad-project-context/references/template.md at bd70c64

Open on GitHub

Most marks come from matching words in the file, so treat them as pointers.

1# Block shape
2
3Sections in this order. Omit any section with nothing that passes its rule — never write an empty one. Admission rules: `best-practices.md`.
4
51. **Orientation** — three or four sentences: what this is, the stack, where planning and deeper docs live.
62. **Policy** — what the org requires.
73. **Where things are** — entry points, and pointers to children and linked files.
84. **Running and verifying** — the right commands to run and the required tool versions, plus what `package.json`, `pyproject.toml`, a `Makefile`, or CI config does not already say.
95. **Conventions that differ from defaults**
106. **Known pitfalls**
12Terse imperative lines under plain headings. No prose beyond Orientation, no introduction, no summary. A bare fact appears only as the justification clause of an instruction — "Exclude `vendor/` from searches, it is 60% of tracked files", never "`vendor/` is 60% of tracked files". A prohibition names the alternative. At most two emphasis markers in the whole block.

Block shape

Sections in this order. Omit any section with nothing that passes its rule — never write an empty one. Admission rules: best-practices.md.

  1. Orientation — three or four sentences: what this is, the stack, where planning and deeper docs live.
  2. Policy — what the org requires.
  3. Where things are — entry points, and pointers to children and linked files.
  4. Running and verifying — the right commands to run and the required tool versions, plus what package.json, pyproject.toml, a Makefile, or CI config does not already say.
  5. Conventions that differ from defaults
  6. Known pitfalls

Terse imperative lines under plain headings. No prose beyond Orientation, no introduction, no summary. A bare fact appears only as the justification clause of an instruction — "Exclude vendor/ from searches, it is 60% of tracked files", never "vendor/ is 60% of tracked files". A prohibition names the alternative. At most two emphasis markers in the whole block.

Raw lines 1 to 13
14## Worked example
16````markdown
17<!-- bmad:context -->
18<!-- Verified 2026-08-08 against a1b2c3d. Managed by bmad-project-context; edits inside this block are replaced on refresh. Keep anything you want preserved outside the markers. -->
20## acme-billing
22Payment processing for Acme storefronts. TypeScript/Node, pnpm, Postgres. Planning lives in `docs/planning/`, tickets in Linear (ACME board).
24## Policy
26- Never push to main; PRs only, one approval.
27- Never modify `legacy/` — frozen, being replaced. New work goes in `src/`.
28- Never hand-edit `src/generated/` — run `pnpm codegen`.
30## Where things are
32- Webhook handling: `src/routes/webhooks.ts`; conventions in `docs/webhooks.md`
33- Writing a migration? Read `docs/db-rules.md` first — ordering, transaction boundaries, pool limits.
34- Billing service has its own guide: `services/billing/AGENTS.md`
36## Running and verifying
38- Run single test files while iterating; the full suite takes ~11 minutes.
39- Integration tests need `docker compose up -d` first, and fail confusingly without it.
40- CI also runs `pnpm typecheck`, which `pnpm test` does not cover.
42## Conventions that differ from defaults
44- Money is integer cents (`amountCents`), never floats — `src/lib/money.ts`
45- All DB access goes through repositories in `src/repos/`; never call the client directly.
47## Known pitfalls
49- Stripe webhooks replay in staging every 6h — handlers must be idempotent.
50- Use vitest matchers, not jest — agents repeatedly add jest syntax here.
52<!-- /bmad:context -->
53````
55Fill the provenance line with the real date and the commit SHA verified against. Refresh diffs from that SHA.

Worked example

<!-- bmad:context -->
<!-- Verified 2026-08-08 against a1b2c3d. Managed by bmad-project-context; edits inside this block are replaced on refresh. Keep anything you want preserved outside the markers. -->

## acme-billing

Payment processing for Acme storefronts. TypeScript/Node, pnpm, Postgres. Planning lives in `docs/planning/`, tickets in Linear (ACME board).

## Policy

- Never push to main; PRs only, one approval.
- Never modify `legacy/` — frozen, being replaced. New work goes in `src/`.
- Never hand-edit `src/generated/` — run `pnpm codegen`.

## Where things are

- Webhook handling: `src/routes/webhooks.ts`; conventions in `docs/webhooks.md`
- Writing a migration? Read `docs/db-rules.md` first — ordering, transaction boundaries, pool limits.
- Billing service has its own guide: `services/billing/AGENTS.md`

## Running and verifying

- Run single test files while iterating; the full suite takes ~11 minutes.
- Integration tests need `docker compose up -d` first, and fail confusingly without it.
- CI also runs `pnpm typecheck`, which `pnpm test` does not cover.

## Conventions that differ from defaults

- Money is integer cents (`amountCents`), never floats — `src/lib/money.ts`
- All DB access goes through repositories in `src/repos/`; never call the client directly.

## Known pitfalls

- Stripe webhooks replay in staging every 6h — handlers must be idempotent.
- Use vitest matchers, not jest — agents repeatedly add jest syntax here.

<!-- /bmad:context -->

Fill the provenance line with the real date and the commit SHA verified against. Refresh diffs from that SHA.

Raw lines 14 to 55
Project instruction file AGENTS.md :34