Reputation: 24344
I would like to create a repo with my dotfiles and some other files I would like to sync across multiple machines. The files are spread across several directories (not only ~
home directory).
Can git keep track of files from several directories that are not necessarily subdirectories to where .git/
is stored?
The best solutions I've come up right now is to make a script to copy dotfiles into single directory where git repo has been init.
Upvotes: 1
Views: 592
Reputation: 6258
What people normally do is have a git repo somewhere, say ~/.dotfiles
and then use symbolic links from that directory to where the dot file should be.
See dotfiles on Github for more inspiration.
Upvotes: 2