This document is for contributors and coding agents working on suitup.
User-facing setup and installation guidance belongs in README.md.
src/cli.jsis the main entry point.src/steps/contains the interactive setup steps.configs/contains the files copied into the user's home directory.tests/contains Vitest coverage for setup flows and generated files.
Suitup generates a thin ~/.zshrc that only orchestrates loading.
The actual config lives under ~/.config/zsh/.
configs/core/perf.zsh: startup timing helpers and report outputconfigs/core/env.zsh: shared environment variablesconfigs/core/paths.zsh: PATH placeholder for user overridesconfigs/core/options.zsh: shell and history options
configs/shared/tools.zsh: thin orchestrator that sourcesshared/tools/_loader.zshand calls_load_tool_configfor each tool moduleconfigs/shared/tools/_loader.zsh:_load_tool_config()helper and_source_cached_tool_init()with version-based cache invalidationconfigs/shared/tools/{tool}.zsh: per-tool module files (fzf, runtime, atuin, bun), loaded on demand by_load_tool_configconfigs/shared/prompt.zsh: prompt/theme loading
configs/local/machine.zsh: machine-specific overrides placeholder~/.config/zsh/local/secrets.zshis user-managed and intentionally not shipped by suitup
configs/zshrc.templateis the default entrypoint.
The template should keep the same loading order unless there is a strong reason to diverge:
- perf
- env
- paths
- options
- tools
- plugin manager
- suitup-managed additions
- local overrides
- prompt
- timing report
src/steps/zsh-config.js is responsible for:
- creating
~/.config/zsh/core,shared, andlocal - copying shipped config files without overwriting user-modified files
- generating
.zshrcfrom the selected template - backing up an existing non-suitup
.zshrcbefore overwrite
This step must remain idempotent.
- Run
npm testfor the full suite. - Zsh config tests live in
tests/zsh-config-steps.test.js. - Tests should verify generated structure and important config content, not just file existence.
- Avoid asserting machine/tool-specific PATH details in setup tests; keep assertions focused on suitup-managed behavior.
- Prefer sandboxed home directories over touching real user files.
README.md: end-user usage, installed tools, resulting file layoutAGENTS.md: implementation details, architecture, contributor guidance
README.md is the source of truth. README.zh-CN.md is its Simplified Chinese translation.
You MUST update both files in the same commit whenever changes affect user-facing content (features, commands, file paths, install behavior, directory layout). Updating one without the other is never acceptable.
Checklist for README changes:
- Paths and directory structures match between both files
- Command tables and descriptions reflect the current behavior
install.shdefault behavior is accurately described in both files- The installed file layout section reflects the current shipped config structure