Record a learning in LEARNINGS.md.
Before Recording
Three questions — if any answer is "no", don't record:
- •"Could someone Google this in 5 minutes?" → If yes, skip it
- •"Is this specific to this codebase?" → If no, skip it
- •"Did it take real effort to discover?" → If no, skip it
Learnings should capture principles and heuristics, not code snippets.
When to Use
- •After discovering a gotcha or unexpected behavior
- •When a debugging session reveals root cause
- •When finding a pattern that will help future work
Execution
bash
ctx add learning "Learning text" --context "..." --lesson "..." --application "..."
Or with just the learning text (will prompt for details):
bash
ctx add learning $ARGUMENTS
Confirm the learning was added.