Use a plan.md File as a Checkpoint That Survives Context Resets
Context windows run out. Sessions crash. You close a tab by accident. When that happens mid-task, you lose everything and have to brief Claude from scratch.
The solution is a plan.md file written before Claude starts building. Keep it simple:
# Add JWT Authentication
## Goal
Add token-based auth to the Express API.
## Steps
- [x] Install jsonwebtoken and bcrypt
- [ ] Create /auth/login and /auth/register routes
- [ ] Add auth middleware to protect existing routes
- [ ] Write integration tests
## Files to touch
- src/routes/auth.ts (new)
- src/middleware/auth.ts (new)
- src/app.ts (register routes)
As Claude completes each step, it checks the box. If the session dies halfway through, start a fresh one and point it at the plan:
Here is the current plan.md. Continue from the first unchecked step.
Claude picks up exactly where it left off. No re-briefing, no repeated context-setting, no trying to reconstruct where things were up to.
This also works when handing a task between parallel sessions. One session writes the plan, another executes it. The plan.md is the shared contract between them.
This is distinct from Claude Code's built-in Plan Mode (Shift+Tab) — that's for the planning conversation itself. A plan.md is a persistent artefact on disk that outlives any single session.
The plan.md is not just a checklist — it is the memory that keeps long work on track.
Log in to leave a comment.
Set up Claude Code as an automated reviewer in your CI pipeline — on every pull request, it reads the diff, checks for bugs, security issues, missing tests, and convention violations, then posts its findings as a PR comment. Your human reviewers get a head start because the obvious issues are already flagged before they look.
Before deploying, tell Claude to read your project — migrations, environment variables, queue workers, scheduled tasks, caching, third-party integrations — and generate a deployment checklist that's specific to your app. Not a generic "did you run migrations?" list, but one that knows YOUR infrastructure and catches the things YOUR deploy can break.
Instead of writing a README from memory or copying a template, tell Claude to read your project and generate one that's actually accurate — real setup instructions from your config, real architecture from your directory structure, real API examples from your routes, and real prerequisites from your dependency files.