2012-01-14 17:30:58 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
# Small script to update my env. Too lazy to write this into my python setup script
|
|
|
|
|
|
|
|
# A die function as always
|
|
|
|
|
|
|
|
die() {
|
|
|
|
printf '%s\n' "$@" >&2
|
|
|
|
exit 1
|
|
|
|
}
|
|
|
|
|
|
|
|
cd
|
|
|
|
|
|
|
|
# Update all the conf files here
|
|
|
|
printf '%s\n' "Updating dotfiles now!"
|
2012-02-06 00:09:28 +00:00
|
|
|
wget --no-check-certificate -O .zshrc https://raw.github.com/staticsafe/dotfiles/master/.zshrc || die 'Download failed!'
|
|
|
|
wget --no-check-certificate -O .vimrc https://raw.github.com/staticsafe/dotfiles/master/.vimrc || die 'Download failed!'
|
|
|
|
wget --no-check-certificate -O .tmux.conf https://raw.github.com/staticsafe/dotfiles/master/.tmux.conf || die 'Download failed!'
|
|
|
|
wget --no-check-certificate -O .conkyrc https://raw.github.com/staticsafe/dotfiles/master/.conkyrc || die 'Download failed!'
|
2012-01-14 17:30:58 +00:00
|
|
|
|
|
|
|
# vim dir
|
|
|
|
rm -r ~/.vim
|
2012-02-06 00:09:28 +00:00
|
|
|
wget -O vimdir.tar.bz2 http://dl.dropbox.com/u/2888062/vimdir.tar.bz2 || die 'Download failed!'
|
2012-03-08 17:21:32 +00:00
|
|
|
tar xjvf vimdir.tar.bz2
|
|
|
|
|
|
|
|
# zsh dir
|
|
|
|
|
2012-03-08 17:32:22 +00:00
|
|
|
if [[ -d ~/dev/dotfiles ]]; then
|
|
|
|
cd ~/dev/dotfiles
|
2012-03-08 17:21:32 +00:00
|
|
|
git pull
|
2012-03-08 17:32:22 +00:00
|
|
|
ln -s ~/dev/dotfiles/.zsh ~/
|
2012-03-08 17:21:32 +00:00
|
|
|
else
|
2012-03-08 17:32:22 +00:00
|
|
|
if [[ -d ~/.zsh ]]; then
|
|
|
|
rm ~/.zsh
|
|
|
|
else
|
|
|
|
printf '%s\n' "No .zsh dir exists."
|
|
|
|
fi
|
2012-03-08 17:21:32 +00:00
|
|
|
mkdir ~/dev
|
|
|
|
cd ~/dev
|
|
|
|
git clone https://github.com/staticsafe/dotfiles.git
|
2012-03-08 17:32:22 +00:00
|
|
|
ln -s ~/dev/dotfiles/.zsh ~/
|
2012-03-08 17:21:32 +00:00
|
|
|
fi
|