Personal dotfiles for reproducible shell and workstation setup, centered on macOS with a Windows bootstrap entrypoint.
This repo bootstraps a machine with packages, shell config, and a small set of app configs while preserving existing user files via timestamped backups.
- Primary: macOS 13+ (Homebrew-based bootstrap).
- Secondary: Windows (WSL-first) via
install/bootstrap-windows.ps1. - Unsupported: Linux for config reuse only; no Linux bootstrap entrypoint.
See Platform Notes for details and prerequisites.
macOS
git clone <repo-url> ~/.dotfiles
zsh ~/.dotfiles/install/bootstrap.zshWindows (PowerShell): Note the ByPass command, review code before executing.
git clone <repo-url> $HOME/.dotfiles
powershell -ExecutionPolicy Bypass -File $HOME/.dotfiles/install/bootstrap-windows.ps1Warning
Review and understand the bootstrap scripts before execution. The dotfiles repo will modify shell configuration files and install packages. Ensure backups exist and you have rollback understanding (see Rollback / Uninstall).
Linux:
- No Linux bootstrap script currently.
- Reuse config modules under
config/zsh/manually.
Global:
zsh --dry-run
zsh --verbosemacOS-only:
zsh --skip-macosWindows-only:
--skip-packages
--link-windows-shell- Cross-platform:
- Idempotent intent: reruns should be safe and mostly no-op when already configured.
- Before relinking
~/.zshrcor~/.zprofile, existing files are moved to timestamped backups (.bak.YYYYmmddHHMMSS).
- macOS:
install/macos.zshis interactive and opt-out via--skip-macos.- macOS setup prompt modes:
- use defaults (no per-setting prompts)
- choose settings (set defaults, then proceed)
- skip
- Windows:
- Validates
wingetpackage IDs before installation. - Checks symlink capability only when
--link-windows-shellis requested.
- Validates
- Shell config:
fzfdefaults are wired tofd(FZF_DEFAULT_COMMAND,FZF_CTRL_T_COMMAND) with hidden files included and shared excludes for heavy paths (for example:.git,node_modules,.cache,dist,build,.next,.turbo,coverage,target).
fcd [root]: fuzzy-select a directory and change into it.ffcd [root]: fuzzy-select a file and change into that file's directory.fview [root]: fuzzy-select a file and view it in-terminal (bat/less).fstack: fuzzy-select adirs -vstack entry and jump to it.
- Shared:
- Symlink targets:
~/.zshrc->~/.dotfiles/config/zsh/.zshrc~/.zprofile->~/.dotfiles/config/zsh/.zprofile
- Zsh module chain via
config/zsh/.zshrc->config/zsh/*.zsh.
- Symlink targets:
- macOS:
- Homebrew packages and casks from
install/Brewfile(includesfd,fzf, andripgrep). - Ghostty symlink:
$XDG_CONFIG_HOME/ghostty/config->~/.dotfiles/config/ghostty/config
- Optional interactive system defaults in
install/macos.zsh.
- Homebrew packages and casks from
- Windows:
- Packages from
install/winget-packages.txtviawinget(when available). - WSL-first guidance output (installs/linking commands for WSL shell environment).
- Windows-host zsh linking only when
--link-windows-shellis passed.
- Packages from
- Linux:
- No package/bootstrap automation managed today.
- Remove symlinks if present.
- Restore backups created by bootstrap (
*.bak.<timestamp>) as needed. - Optionally uninstall managed packages.
- Remove the repo clone.
macOS cleanup commands:
rm -f ~/.zshrc ~/.zprofile
rm -f ${XDG_CONFIG_HOME:-$HOME/.config}/ghostty/config
brew bundle cleanup --file ~/.dotfiles/install/Brewfile --force
rm -rf ~/.dotfilesWindows cleanup commands:
Remove-Item $HOME\.zshrc,$HOME\.zprofile -Force -ErrorAction SilentlyContinue
# Then remove package installs manually or via winget uninstall as needed.
Remove-Item $HOME\.dotfiles -Recurse -ForceLinux cleanup:
- Remove any manual symlinks you created.
- Remove repo clone.
- macOS bootstrap:
install/bootstrap.zsh - Windows bootstrap:
install/bootstrap-windows.ps1 - macOS tuning (optional):
install/macos.zsh - macOS package manifest:
install/Brewfile - Windows package manifest:
install/winget-packages.txt - Shell entrypoint chain:
config/zsh/.zshrc->config/zsh/*.zsh
Run after changing install/config behavior:
shellcheck install/*.zsh config/zsh/*.zsh
shfmt -w -i 2 -ci install/*.zsh config/zsh/*.zsh
brew bundle check --file ~/.dotfiles/install/BrewfileWindows package manifest check:
Get-Content $HOME/.dotfiles/install/winget-packages.txt | `
Where-Object { $_ -and -not $_.StartsWith('#') } | `
ForEach-Object { winget search --id $_ -e }If available:
dot doctor
- Scripts should not delete user files by default.
- No secret material (tokens/keys/passwords) should be committed.
- Network installs are limited to explicit bootstrap dependencies (
brew,winget,git,curl).
See:
