Skip to content

Instantly share code, notes, and snippets.

@tomarak
Created March 22, 2016 18:17
Show Gist options
  • Save tomarak/f87b97bb84080907aaa4 to your computer and use it in GitHub Desktop.
Save tomarak/f87b97bb84080907aaa4 to your computer and use it in GitHub Desktop.
install prezto on vagrant box
# Usage: curl -L https://gist.github.com/tomarak/f87b97bb84080907aaa4.sh | zsh && chsh -s $(which zsh)
#
echo "Cloning prezto"
rm -rf "${ZDOTDIR:-$HOME}/.zprezto"
git clone --recursive https://github.com/sorin-ionescu/prezto.git "${ZDOTDIR:-$HOME}/.zprezto"
echo "Symlinking all requires zsh dot files"
setopt EXTENDED_GLOB
for rcfile in "${ZDOTDIR:-$HOME}"/.zprezto/runcoms/^README.md(.N); do
targetfile=${ZDOTDIR:-$HOME}/.${rcfile:t}
rm -f "$targetfile"
ln -s "$rcfile" "$targetfile"
done
echo "Include git prezto module"
sed -i "s/'prompt'/'prompt' 'git'/" ${ZDOTDIR:-$HOME}/.zpreztorc
echo "Remove git aliases from the git prezto module"
sed -i '/^alias/d' ${ZDOTDIR:-$HOME}/.zprezto/modules/git/alias.zsh
echo "done"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment