dotfiles/sync.sh

19 lines
401 B
Bash
Raw Normal View History

2019-02-07 10:49:20 +00:00
#!/bin/bash
# Adrien Luxey - Feb. 2019
# Script inspired by https://github.com/mathiasbynens/dotfiles/blob/master/bootstrap.sh
# cd to this file's directory
cd "$(dirname "${BASH_SOURCE}")";
2019-02-07 11:29:56 +00:00
git pull origin master
2019-02-07 10:49:20 +00:00
# Get dotfiles (and dot directories) in current directory
dotfiles=$(find . -maxdepth 1 -regex "\./\..+" -printf "%f\n")
2019-02-07 11:29:56 +00:00
function syncDotfiles() {
2019-02-07 10:49:20 +00:00
ln -s $dotfiles ~
}
2019-02-07 11:29:56 +00:00
syncDotfiles