Personal Zsh-first dotfiles for daily terminal work on macOS and Linux.
Phase-based loader for shell startup.
The _dotfiles_source_dir helper sources *.zsh files from phase directories in order.
Startup flow:
.zshenv(always):zshenv/pre-init->zshenv/init->zshenv/post-init.zprofile(login shells):zprofile/pre-init->zprofile/init->zprofile/post-init.zshrc(interactive shells):zshrc/pre-init->zshrc/init->zshrc/post-init
Phase intent:
pre-init: environment/bootstrap (PATH,FPATH, completion prerequisites)init: aliases, functions, plugin setup, core behaviorpost-init: widgets, keybindings, terminal/UI hooks
Placement rule: add new behavior as a focused file in the correct phase directory instead of expanding entrypoint files.
zshgitstowshellcheckgh_source(for plugin management)
Frequently used optional tools in this setup include gh, fzf, bat, rg, fd, atuin, starship, and cargo.
- Keep changes modular: add/update a focused file in the proper phase directory.
- Avoid broad inline
sourceblocks in.zshenvor.zshrc. - Follow existing
gh_sourceusage for plugin sourcing. - Use
gh_source --requireonly for hard dependencies.