Website: dotfiles.ryck.dev, with a one-page reference of the shortcuts, aliases and plugins below.
There are tons of useful things in here:
- The usefulness of Oh My ZSH! is already builtβin.
- Starship as a prompt.
- Tmux configured in
~/.tmux.conf, with tmux-lean: a minimal theme with process icons and light/dark colors. - Fish-like autosuggestion in Zsh.
- Syntax highlighting of commands while they are typed.
- Automatically closing and deleting of quotes and brackets when you type them.
- Browser-like substring search for history.
- zgenom (maintained fork of zgen) for dependency management.
- mise for Node, Python and Go versions (replaces nvm, fnm and pyenv).
- Atuin for searchable, synced shell history on
Ctrl-R. - fzf and fzf-tab for fuzzy file, folder and completion pickers.
- VS Code as
$EDITOR, with the fresh terminal editor as fallback. - Lots of useful aliases.
- Modern CLI tools like
eza(smarterls),bat(smartercat),zoxide(smartercd),delta,lazygit,ripgrep,fd,btop. - Git config, global
.gitignorefile and aliases. - Homebrew bundle for bootstrapping a macOS workstation (every package is listed in
Brewfile.md). - A lot of useful bins.
updatescript for updating dotfiles, Zsh plugins, brew, mise runtimes, and apt packages.
Missing feature? Fork this repo and make it better.
~/.configis a real directory, not a symlink into the repo. Linking the whole folder would let every app write its state into the repo, so only the apps inconfig/are linked one by one. See How~/.configworks.- App-owned configs (gh) are copied once from
seed/instead of linked.scripts/sync.shcompares them with the repo. updaterefuses to pull over local edits and pulls with--rebase --autostash.
- zgenom instead of zgen, which is archived. It's pinned to
~/.zgenom. - Fewer Oh My Zsh plugins: dropped
nvm,fnm,pyenv,deno, a duplicatedirenv,gpg-agent,ssh-agent,codex,nodeandyarn. Addedmise. - tinted-shell instead of the abandoned base16-shell.
- zsh-you-should-use instead of alias-tips, which started Python before every command (~30ms each).
- fast-syntax-highlighting instead of zsh-syntax-highlighting.
- Starship instead of Spaceship, configured in
config/starship: Starship's defaults with Nerd Font icons for Go, Node, Python and package versions, plus lines added and removed in the repo (+3 -27), and how long slow commands took on the right. The AWS and gcloud profiles are hidden. Theβ―turns red when a command fails. Inside a project it shows the Node, Go or Python version mise picked for it. The whole prompt draws in ~45ms, where Spaceship showed part of it after ~65ms and filled in versions ~0.4s later. Its init script is cached, so it adds nothing to startup. - New Oh My Zsh plugins:
copypath(copy the current folder's path),copyfile(copy a file's contents),copybuffer(Ctrl-Ocopies what you've typed),dirhistory(Option-β/βback/forward through visited folders,Option-βparent folder),uv(completions),git-commit(git feat -s zshrc "msg"βfeat(zshrc): msg),magic-enter(Enteron an empty prompt runsgst -u .in a repo,lselsewhere) andaliases(als gitsearches your aliases). _extend_pathchecksPATHin pure zsh instead of runningecho | tr | grepon every call.EDITORis VS Code (code --wait), falling back to fresh, thennano, thenvim. Over SSH VS Code is skipped. Git and lazygit follow it.XDG_CONFIG_HOMEis set.- Personal settings live in tracked
lib/exports.zshandlib/functions.zsh.custom/stays a gitignored extension point.
- mise manages Node (LTS), Python (latest) and Go (latest), replacing nvm, fnm and pyenv.
updateupgrades them, andbootstrap.shinstalls them. - New CLI tools: atuin (history search on
Ctrl-R), lazygit, ripgrep, fd, jq, yq, btop, tealdeer, uv, hyperfine (benchmarking). - Brewfile is rebuilt from what's actually installed on my Mac, with unused apps removed. Third-party taps are marked
trusted: true.Brewfile.mdexplains how to use it and describes every package. brew-usagelists installed Homebrew packages by when you last used them, to find ones to remove.
Measured on my Mac with time zsh -i -c exit (warm, average of 3 runs):
| Step | Startup |
|---|---|
| Original setup (zgen, all plugins) | ~0.85s |
| zgenom + dropping nvm/fnm/pyenv/deno | ~0.72s |
Dropping gpg-agent, ssh-agent, codex, node |
~0.34s |
Dropping yarn |
~0.22s |
Pure-zsh _extend_path |
~0.18s |
Adding you-should-use, fast-syntax-highlighting, copypath, copyfile, copybuffer, dirhistory, uv |
~0.20s |
Starship instead of Spaceship (measured with hyperfine, 20 runs) |
~0.21s (Spaceship: ~0.22s) |
That's about 4Γ faster than the original setup, with more features. Most of the gain came from gpg-agent, which ran gpgconf on every shell start (~380ms), and yarn, which ran yarn global bin (~130ms).
Tell Git who you are using these commands:
git config -f ~/.gitlocal user.email "email@yoursite.com"
git config -f ~/.gitlocal user.name "Name Lastname"Clone dotfiles repo:
# Clone dotfiles repo
git clone https://github.com/ryck/dotfiles.git $HOME/.dotfiles
# Go to the dotfiles directory
cd $HOME/.dotfiles
# Install dotfiles
./installOn a new Mac, then bootstrap it. This installs Homebrew, Git and Zsh, everything in the Brewfile (including mise), the Node/Python/Go runtimes from config/mise via mise install, and a few global npm packages:
./scripts/bootstrap.sh./install also links config/agents/AGENTS.md into supported agent config directories when those directories already exist: ~/.codex, ~/.cursor, ~/.config/github-copilot, ~/.config/opencode, and ~/.claude (as CLAUDE.md).
Use a single command to get the latest updates:
updateThis command refreshes sudo, pulls the latest dotfiles, reruns ./install --except shell, updates zgenom and Zsh plugins, and updates brew and mise when available.
update refuses to pull if the repo has uncommitted changes. Commit them, or move machine-specific settings to ~/.zshlocal, ~/.gitlocal or custom/.
~/.config is a real directory, not a symlink to this repo. Apps can write whatever they want there without touching the repo.
- Linked configs live in
config/and are symlinked per app byinstall.conf.yaml(~/.config/ghosttyβconfig/ghostty, etc.). Editing them edits the repo. To track a new app, move its folder intoconfig/and add alink:line. - App-owned configs that apps rewrite themselves (gh
config.yml) live inseed/.scripts/seed.shcopies them into$HOMEonce, only if they're missing, so the app owns the live copy and the repo never gets dirty../scripts/sync.shshows a diff between the live copies andseed/../scripts/sync.sh --pullcopies the live copies intoseed/so you can review and commit them.
Note: You may put your custom settings into
~/.zshlocal, or intocustom/*.zsh(loaded automatically and never committed).
I suggest you to organize project folder as follows:
~/Projects
βββ Forks # for GitHub fork
βββ Job # for job projects
βββ Playground # for short-term experiments
βββ Repos # for long-term projects| Keys | Does |
|---|---|
Ctrl-R |
Search history with Atuin. Press Ctrl-R again to switch between all history, this machine, this session, and this folder. |
β / β |
Search history for commands starting with what you've typed |
Tab |
Completion menu you can fuzzy-search (fzf-tab) |
Ctrl-T |
Pick a file with fzf and insert its path |
Esc then C |
Pick a folder with fzf and cd into it (Option-C if your terminal sends Option as Alt) |
Esc Esc |
Re-run the current or previous command with sudo |
Ctrl-O |
Copy what you've typed to the clipboard without running it |
Enter on an empty prompt |
Run gst -u . (git status) in a repo, ls -lh elsewhere (magic-enter) |
Option-β / Option-β |
Back / forward through folders you've visited (dirhistory) |
Option-β / Option-β |
Go to the parent folder / into the first subfolder |
Ctrl-β / Ctrl-β |
Jump one word back / forward |
... |
Typing dots expands them: ... β ../.. |
Aliases are going to make your work fast and enjoyable. See code in $DOTFILES/lib/aliases.zsh. Here is what's included:
- Aliases from Oh-My-Zsh. See Oh-My-Zsh Cheatsheet for more.
- Easier navigation
..βcd .....βcd ../......βcd ../../.......βcd ../../../..~βcd ~-βcd -
- Folders shortcuts
dlβcd ~/Downloadsdtβcd ~/Desktoppjβcd ~/Projectspjrβcd ~/Projects/Repospjfβcd ~/Projects/Forkspjjβcd ~/Projects/Jobpjlβcd ~/Projects/Playground
- Commands Shortcuts
eβ open in$EDITORwithout waiting (VS Code)+xβchmod +xx+βchmod +xreloadβ reload~/.zshrcclrβclearqβ go home and clear the screen
- Open
open <FILE>β open file from terminal.o <FILE>β open file from terminal.ooβ open current folder.termβ open iTerm.
- macOS
show/hideβ show or hide hidden files in Finder.cleanupβ recursively delete.DS_Storefiles.cdfβcdinto the folder open in the front Finder window.copypathβ copy the current folder's path.copyfile <file>copies a file's contents.
- Misc
updateβ get updates (Runs$DOTFILES/scripts/update.sh).bootstrapβ run machine bootstrap (Runs$DOTFILES/scripts/bootstrap.sh).dotfilesβ jump quickly into dotfiles folder.myipβ my local IP address.passwordβ generate random password, copies it into clipboard and outputs it to terminal.pathβ print $PATH in readable view.getpageβ download web page with all assets.getβ download file with original filename.git-root/cdgrβ jump to the current repo root.mkd <dir>β create a folder andcdinto it.extract <file>β unpack any archive.
- Tools (only when installed)
helpβtldr.lgβlazygit.md <file>β render Markdown withglow.topβbtop.ltβ tree view witheza;lβ long list;laβ long list including hidden files.ccβclaude;ccxβ Claude Code in~/Projects/Playgroundwith auto permissions.cxβcodex;cxxβ Codex in~/Projects/Playgroundwith--full-auto.
Depending on installed tools, ls uses eza, cat uses bat, cd uses zoxide, and top uses btop. rm, cp and mv ask before deleting or overwriting (-i, from the common-aliases plugin).
Oh My Zsh plugins (see .zshrc):
- Git & GitHub:
git(aliases likegst,gco,gp),git-commit(git feat,git fix,git chore⦠for conventional commits),gh(completions). - History & navigation:
history-substring-search,fzf,zoxide,dirhistory. - Runtimes & packages:
mise(seeconfig/mise),npm,uv,brew,direnv. - Containers & terminal:
docker,docker-compose,tmux. - Helpers:
sudo,extract,copypath,copyfile,copybuffer,magic-enter,aliases(als),common-aliases,command-not-found,tldr,macos,vscode.
Other plugins:
- Starship prompt, configured in
config/starship. - fast-syntax-highlighting and zsh-autosuggestions.
- fzf-tab for fuzzy
Tabcompletion, plus zsh-completions. - zsh-you-should-use reminds you when an alias exists for what you typed.
- zsh-autopair closes quotes and brackets.
- omz-plugin-pnpm: pnpm aliases (
p,pa,pad,pin,pr,pd,pb,pt,pdxβ¦) andPNPM_HOMEonPATH. Itspreplaces common-aliases'p(ps -f). - tinted-shell for base16 terminal color schemes.
Dotfiles also include some functions that will make your life easier. See code in bin/.
brew-usageβ list installed Homebrew formulae and apps by when you last used them, to spot ones you can remove.emptytrashβ empty the Trash on all mounted volumes and the main HDD.git-cleanupβ removes old Git branches and does other cleanup.git-forkβ add remote upstream.git-upstreamβ sync branch with upstream.gzβ get gzipped file sizenβ runs given command using binary innode_modules/.binof the current project.nyanβ print nyan cat.passwordβ generate a random password and copy it to the clipboard.
Note: Add your git user data and custom settings to
~/.gitlocal.
- UI color is
auto. - Default branch is
main. - Diff colors are:
white boldfor meta information;cyan boldfor frag;red boldfor old lines;green boldfor new lines.
- Diffs are shown with delta (line numbers,
n/Nto jump between files, clickable paths). - Editor follows
$EDITOR(VS Code locally, fresh over SSH or without VS Code). push.defaultset ascurrent.pull.rebaseset totrue.push.autoSetupRemoteset totrue.rerereenabled for conflict resolution reuse.- Automatic replacement
git://github.com/,gh:,github:addresses asgit@github.com:for GitHub. - Automatic replacement
git://gist.github.com/,gst:,gist:addresses asgit@gist.github.com:for Gists. - User custom settings gets from a
~/.gitlocalfile.
git aβgit addβ stage files.git uaβgit reset HEADβ unstage files.git bβgit branchβ list, create, or delete branches.git cβgit commitβ record changes to the repository.git mβgit mergeβ merge branches.git mcβgit merge --continueβ continue merge after resolving conflicts.git coβgit checkoutβ checkout a branch or paths to the working tree.git cbβgit checkout -bβ create and checkout branch.git swβgit switchβ switch branches.git swcβgit switch -cβ create and switch branch.git apβgit add -pβ stage changes hunk by hunk.git caβgit commit -aβ commit with automatically stage files that have been modified and deleted.git cmβgit commit -mβ commit with commit message.git camβgit commit -amβ add all files and commit with message.git sβgit status -sbβ short status with current branch.git mainβ go tomainbranch and pull from remote.git masterβ go tomasterbranch and pull from remote.git developβ go todevelopbranch and pull from remote.git memain/git memasterβ fetch latestmain/masterand merge it into the current branch.git remain/git remasterβ fetch latestmain/masterand rebase the current branch onto it (with autostash).git gitβ do not complain aboutgit git.git lβ commits log with pretty single line format.git llβ log with list of changed files for each commit.git ignoreβ ignore files: append file to.gitignore.git thisβ initialize, add all files and commit.git amendβ amend last commit.git redoβ amend last commit with its original message.git undoβreset --mixed HEAD^β reset index changes, but not the working tree.git discardβcheckout --β discard changes.git contribβ list of contributors and how many commits each person has.git todayβ see how many lines of code you have written today.git syncβ pull and push changes from/to remote.git lazyβ openlazygit.git-rootβ go to repo root.git-cleanup [--force]β removes old Git branches.git-fork <original-author>β add remote upstream.git-upstream [branch]β sync branch with upstream (defaults tomaster).
Resources that I used to make these dotfiles better:
Originally based on Denys Dovhanβs dotfiles.
MIT Β© Denys Dovhan, Ricardo Gonzalez
