Standard symlinking tools like GNU Stow are bloated
and unnecessary. By using a bare repository, we can track configuration
files directly in $HOME without the mess.
Setup
First, initialize the bare repository:
git init --bare $HOME/.cfgThen, define a local alias to interact with it:
alias dots='/usr/bin/git --git-dir=$HOME/.cfg/ --work-tree=$HOME'Why this is superior
- No Symlinks: Files live exactly where they belong
in
~/.config. - Minimalism: Relies only on Git—no external binaries or scripts required.
- Portability: Cloning to a new machine is a single-step process.