Use this with ex. Dropbox to keep your configuration files synced between your workstations using symbolic links
I was inspired by Ira's mackup, but I needed to have some configuration files shared between all my computers (ex. ~/.vimrc), and some available in Dropbox under their own hostname folders for backup-purpose (ex. ~/.ssh).
Put the symbolize script in your $PATH, or run the following if you have Snap:
snap install symbolize
symbolize SOURCE DESTINATIONFOLDER
symbolize ~/.ssh ~/Dropbox/config/$HOSTNAME
WARNING: The following folder does not yet exist:
/home/slimg/Dropbox/config/maggie
Do you want to create it? (y|n) :
y
Running: mkdir -p "/home/slimg/Dropbox/config/maggie"
Running: mv "/home/slimg/.ssh" "/home/slimg/Dropbox/config/maggie/.ssh"
Running: ln -s "/home/slimg/Dropbox/config/maggie/.ssh" "/home/slimg/.ssh"
symbolize ~/.vimrc ~/Dropbox/config/shared
Running: ln -s "/home/slimg/Dropbox/config/shared/.vimrc" "/home/slimg/.vimrc"
symbolize ~/.irssi ~/Dropbox/config/shared
WARNING: Both exist.
Options:
d: Sacrifice "/home/slimg/.irssi"
s: Sacrifice "/home/slimg/Dropbox/config/shared/.irssi"
n: Don't do anything.
What do you want to do? (d|s|n) :
s
Running: rm -R "/home/slimg/Dropbox/config/shared/.irssi"
Running: mv "/home/slimg/.irssi" "/home/slimg/Dropbox/config/shared/.irssi"
Running: ln -s "/home/slimg/Dropbox/config/shared/.irssi" "/home/slimg/.irssi"