dotfiles/update.sh

19 lines
398 B
Bash
Raw Normal View History

2017-11-03 07:09:33 +00:00
#!/bin/bash
GIT_DIRS=(. ~/.vim/bundle ~/.config/nvim ~/.tmux/plugins/tpm)
2017-11-03 07:09:33 +00:00
for dir in ${GIT_DIRS[@]} ; do
if [ -d "$dir" ] ; then
2022-02-14 20:37:02 +00:00
git -C "$dir" git stash
git -C "$dir" pull
git -C "$dir" git stash pop
else
echo "Skipping: $dir"
fi
2017-11-03 07:09:33 +00:00
done
if type nvim &>/dev/null ; then
nvim -c "autocmd User PackerComplete quitall" -c "PackerSync"
fi
2017-11-03 07:09:33 +00:00
vim -c ":PluginUpdate" -c ":q" -c ":q"