| name | tracer-bullets |
| description | Codemap feature layers and worked tracer-bullet examples โ vertical slices for new source extensions, SQLite schema changes, and CLI flags. Use when planning a feature as a tracer bullet and deciding slice boundaries across CLI/parser/db/test/docs layers. |
| disable-model-invocation | true |
Tracer bullets โ codemap feature layers and examples
Always-on rule: .agents/rules/tracer-bullets.md (the 5 rules + lite-harden). This skill carries the codemap layer map and worked examples.
Feature layers in this project
A typical vertical slice for codemap touches these layers top-to-bottom:
- CLI / orchestration โ
src/cli/ (bootstrap.ts, main.ts, lazy cmd-* chunks; entry src/index.ts)
- Workers / parsing โ
src/parse-worker.ts / parse-worker-node.ts, parse-worker-core.ts, src/parser.ts, src/css-parser.ts, src/adapters/
- Persistence โ
src/db.ts (schema, inserts, SCHEMA_VERSION)
- Config / runtime โ
src/config.ts, src/runtime.ts, resolver
- Tests โ
src/*.test.ts
- Docs โ
docs/*.md when behavior is user-visible
Example 1: Support a new source extension
Bad โ building in layers:
- Update every glob, parser, and docs in one giant change
- Hope CI and the index agree
Good โ tracer bullet:
constants + adapter โ LANG_MAP + builtin adapter extensions + extractFileData โ commit, bun run check, small test parsing a one-line file
- Resolver โ
resolver extensions if needed โ commit, validate
- Docs โ
docs/architecture.md table row โ commit, validate
Example 2: Add a new SQLite column or table
Bad โ schema + all call sites + benchmarks in one unreviewable diff.
Good โ tracer bullet:
- Schema + insert path โ
db.ts + one write path exercised by a test or CLI run โ commit, validate
- Readers / query UX โ expose in
query or docs โ commit, validate
- Benchmark / fixtures โ if numbers matter โ separate commit
Example 3: New CLI flag
Bad โ flag parsing, help text, config, and tests all speculative.
Good โ tracer bullet:
- Parse flag + minimal behavior โ e.g.
--dry-run that only logs โ commit, test
- Wire to real work โ connect to indexer โ commit, validate
- Document โ README /
docs/architecture.md โ commit
Commit cadence
Each commit should represent a functional, describable milestone โ not a placeholder. Every tracer bullet is a shippable slice that works end-to-end, even if the feature isn't complete yet. Small commits get validated by the pre-commit hook and are easier to review and revert.
Before opening a PR, run harden-pr in full mode on origin/main...HEAD (or accept the offer when the plan checklist is complete).