Before writing code:
- Read
feature_list.json(active/next-up work — GitHub Issues onfirstsun-dev/git-files-sync, Project #6, is the real source of truth; re-sync stale entries) andprogress.md(what's currently open). - Read
session-handoff.mdfor the previous session's exact stopping point. - Run
./init.shto confirm a clean, green baseline before editing.
A feature is done only when all of the following hold, with evidence recorded (command + result) in progress.md:
npx eslint .— 0 errorsnpm run build— passes (tsc + Obsidian 1.11.0 compat typecheck + esbuild)npx vitest run— passes- Manual verification in Obsidian, when the change has a runtime UI surface
- One feature at a time: pick a single
feature_list.jsonentry and finish it (with recorded evidence) before starting the next. - Don't expand scope mid-task — file a new GitHub issue via the
firstsun-pmskill instead of quietly bundling unrelated work.
Before ending a session:
- Overwrite
session-handoff.md(don't append) with the new stopping point so the repo stays restartable. - Move finished items from
progress.mdintoarchive/YYYY-MM.md(current month) — next steps inprogress.mdshould read as a short list, not a changelog.
- Sonnet 4.6 (Primary): Orchestrator for complex planning and architecture.
- Opus (Architect): Deep research and large-scale refactoring.
- Haiku (Specialized): Fast, token-efficient model for TDD, linting, and CI/CD monitoring. REQUIRED: All verification tasks MUST be offloaded to Haiku to save tokens.
- Subagents: Isolated tasks for context protection.
- Rule: Write Vitest tests BEFORE implementation.
- Execution: Offload
npx vitest runandnpm run lintto Haiku. - Report Format:
Success: N items, Failure: X items(including error logs on failure).
- Rule: Verify compliance before any release candidate.
- Checks:
manifest.jsonparity,isDesktopOnlylogic, andonunloadcleanup.
- Rule: Post-push monitoring by Haiku in the background.
- Failure Protocol: Fetch and return specific error messages from the CI pipeline.
- Pre-commit: Husky hook running
npm run lint && npm run build.