Last active
November 3, 2016 22:09
-
-
Save mavcunha/bd53e9beec494ab9a7c88f6ba1c6c633 to your computer and use it in GitHub Desktop.
Grind vim installation configuration
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# vim: ft=sh | |
do_run "brew install vim" | |
unless_file "/usr/local/bin/vim" | |
do_run "git clone https://github.com/mavcunha/vim.git ${HOME}/Projects/vim" | |
unless_dir "${HOME}/Projects/vim" | |
do_run "mkdir -p ${HOME}/.vim/bundle" | |
unless_dir "${HOME}/.vim/bundle" | |
do_run "ln -f -s ${HOME}/Projects/vim/vimrc ${HOME}/.vimrc" | |
unless_link "${HOME}/.vimrc" | |
function install_bundles() { | |
local bundles=("${!1}") | |
for b in ${bundles[@]}; do | |
local repo=${b} | |
local target=${b#*/} | |
do_run "git clone https://github.com/${repo}.git ${HOME}/.vim/bundle/${target}" | |
unless_dir "${HOME}/.vim/bundle/${target}" | |
done | |
} | |
vim_bundles=( | |
'tpope/vim-pathogen' | |
'tpope/vim-surround' | |
'tpope/vim-unimpaired' | |
'mavcunha/rainbow_parentheses.vim' | |
'vim-ruby/vim-ruby') | |
install_bundles vim_bundles[@] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment