I manage my dotfiles with the help of the GNU Stow package. Bastian Venthur's and Brandon Invergo's articles were of much help when deciding this setup. I previously used a different solution.
Also, dotfiles are meant to be forked.
Files are kept within a directory named after the tool they belong to. Inside that directory the target directory structure is mimicked. When specific tags are needed, an additional layer is put in place.
One-line example to remind myself on how to use this setup.
From within ~:
stow --no-folding -d ~/dotfiles -S nvim -t ~ -v3
--no-folding: Stow only the leaves, not the branches. This means that only files will be stowed —directories will be created if they do not exist, but won't be symlinked.-d: The stow directory where the package is located at.-S: The package to be stowed.-t: The target directory. This is usually/home/userin Linux and/Users/userin macOS.-v3: Verbosity level 3.