Tips, tricks, and lessons from building software.
Tips, tricks, and lessons from building software — a personal dev blog by Tommy.
Writing a CLAUDE.md That Claude Actually Follows
A CLAUDE.md works best when it uses concrete rules over vague advice and skips anything Claude could already learn from the code.
Importing Files into CLAUDE.md with @
Use an @path reference inside CLAUDE.md to pull in another file, keeping the main memory file short while sharing detailed guidance.
Personal vs Project vs Local Memory
Claude Code has three kinds of memory file: personal for all your projects, project for the team, and local for private per-project notes.
Adding Memory on the Fly with #
Type a line starting with # during a session to save a quick note straight into your CLAUDE.md without leaving the conversation.
Keeping CLAUDE.md Small and Focused
A short CLAUDE.md works better than a long one; aim under about 200 lines and cut anything Claude can infer from the code.
Generating a CLAUDE.md with /init
The /init command scans your project and writes a starter CLAUDE.md so you do not have to build one from a blank file.