···2828- avoid barrel exports (index files that re-export from other modules); import directly from source
2929- use `// #region <name>` and `// #endregion` to denote regions when a file needs to contain a lot
3030 of code
3131-- optional parameters should only exist when callers actually vary in what they pass:
3232- - if all callers use the default, hardcode it instead of making it a parameter
3333- - if all callers must pass a value (e.g. forwarding), make it required
3434- - good optional parameters: config values with sensible defaults that some callers override (e.g.,
3535- `timeout = 5000` where most use the default but some need custom values)
3636-- avoid optional parameters that change behavioral modes; prefer separate functions instead
3131+- prefer required parameters over optional ones; optional parameters are acceptable when:
3232+ - the default is obvious and used by the vast majority of callers (e.g., `encoding = 'utf-8'`)
3333+ - it's a configuration value with a sensible default (e.g., `timeout = 5000`)
3434+- avoid optional parameters that change behavioral modes or make the function do different things
3535+ based on presence/absence; prefer separate functions instead
3736- when adding optional parameters for backwards compatibility, consider whether a new function with
3837 a clearer name would be better
3938···67666867### Claude Code-specific
69687070-- Bash tool persists directory changes (`cd`) across calls; always specify cd with absolute paths to
7171- be sure
7272-- Task tool (subagents for exploration, planning, etc.) may not always be accurate; verify subagent
7373- findings when needed
6969+- Explore tool (subagents for exploration, planning, etc.) may not always be accurate; verify
7070+ subagent findings when needed
74717572### cgr
7673···81788279options:
8380 -m, --model <model> model to use: opus, sonnet, haiku (default: haiku)
8484- -s, --shallow use shallow clone (depth 1) for faster cloning
8181+ -d, --deep clone full history (enables git log/blame/show)
8582 -w, --with <repo> additional repository to include, supports #branch (repeatable)
8683```
8784