laughing-hipster/bootstrap.sh

20 lines
419 B
Bash
Executable File

source=$(pwd)
bkup=~/dotfile_bkup
dest=~
mkdir -p $bkup
echo "making a backup of old dotfiles into ${bkup}"
ls -A ${dest} | grep ^\\..* | xargs -I file cp ~/file ${bkup}/file
echo "loading modules"
git submodule init
git submodule update
echo "linking dotfiles from ${source} into ${dest}"
cd ${dest}
ls -A ${source} | xargs -I file cp --symbolic-link -r ${source}/file ${dest}
rm -rf ~/.git
rm -rf ~/bootstrap.sh