Last active
March 22, 2020 20:45
-
-
Save J3698/802340915e8a8036d9a9f041157ee4c0 to your computer and use it in GitHub Desktop.
Install vim with autocomplete
This file contains hidden or 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
#!/usr/bin/env bash | |
# clone vim and vundle | |
cd ~ | |
git clone https://github.com/vim/vim.git | |
git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim | |
# build vim | |
cd vim | |
git checkout a21df1db3ca619afdcb47931af042508a6bbc8e5 | |
./configure --enable-python3interp | |
make install DESTDIR=~/.local | |
# install vim | |
afsuser=`pwd | cut -d "/" -f 4` | |
echo "export VIMRUNTIME=\"/afs/andrew.cmu.edu/$afsuser/$USER/.local/usr/local/share/vim/vim82\"" >> ~/.bashrc | |
echo "alias vim=\"~/.local/usr/local/bin/vim\"" >> ~/.bashrc | |
source ~/.bashrc | |
# setup .vimrc | |
wget "https://gist.githubusercontent.com/J3698/c0c812d83f438bb472bb1ed9cd79e3d6/raw/19a456122405bf3bc5b27d025f2908153286759b/.newvimrc" | |
mv .newvimrc ~/.vimrc | |
# install plugins | |
vim +PluginInstall +qall | |
python3 ~/.vim/bundle/youcompleteme/install.py --clangd-completer | |
# cleanup | |
cd ~ | |
rm -rf vim | |
echo -e '\n\nAll done!' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment