Claude Code cheatsheet
Claude Code: Inside a session
11 common Claude Code tasks.
Create a CLAUDE.md
Analyze the project and write a CLAUDE.md with build commands and conventions.
/init
Shrink a long conversation
Summarize the history to free up context. Add instructions about what to keep.
/compact keep the failing test names
Run a shell command
Start a line with ! to run it in your shell and add the output to the conversation.
!git status
Mention a file
Type @ then a path to add that file to the conversation.
@src/app.ts explain how this works
Learn the keyboard shortcuts
Shift+Tab cycles permission modes, Esc interrupts Claude, and pressing Esc twice lets you go back and edit an earlier message.
Shift+Tab cycle permission modes
Esc interrupt Claude
Esc Esc rewind to an earlier message