6 ms·
I use this: https://github.com/holman/dotfiles.git https://github.com/holman/dotfiles.git Dotfiles are stored in git, and run a script that creates symlinks to
by lionyo 7y ago
I use this: https://github.com/holman/dotfiles.git https://github.com/holman/dotfiles.git
Dotfiles are stored in git, and run a script that creates symlinks to those dotfiles
- tomjakubowski 7y agoI do something like this, but I lean on GNU Stow[1] to manage the symlinks. My ~ directory tree, early on in setting up a new system, might look like: ~/ .config/ dotfiles/ i3/ .config/ i3/ config zsh/ .config/ zshenv.d/ README.txt .zshenv .zshrc When I want to use a package, I cd to ~/dotfiles and run: stow zsh Running that sets up symlinks rooted one directory above, ~. Now ~ looks like: ~/ .config/ zshenv.d/ -> ../dotfiles/zsh/.config/zshenv.d/ dotfiles/ (as earlier) .zshenv -> ../dotfiles/zsh/.zshenv .zshrc -> ../dotfiles/zsh/.zshrc Because ~/.config already existed, stow made the zsh symlink inside it. If ~/.config hadn't existed, stow would have symlinked it from ~/dotfiles/zsh. To remove the symlinks stow set up: stow -D zsh I did eventually set up a wrapper script to pass a few default arguments to stow, to ignore certain files I use for documentation. But stow does all of the work of managing the symlinks. [1]: https://www.gnu.org/software/stow/manual/stow.html#Introduction https://www.gnu.org/software/stow/manual/stow.html#Introduct...