Skip to content

Instantly share code, notes, and snippets.

@sevko sevko/README.md
Last active Oct 6, 2019

Embed
What would you like to do?
Compile a full-featured Vim (w/ Python, Ruby, etc.).

compile full Vim

The default Vim installed on most Linux distros lacks a number of vital features, like xterm_clipboard (allows copy-and-pasting to the system clipboard) and python (on which certain plugins rely). The compile_full_vim.sh shell script removes the currently installed Vim and compiles a full-featured version; it's based entirely off Valloric's YouCompleteMe walkthrough, which it bundles into a simple script for convenience. Vim will be compiled with the following feature flags:

  • --with-features=huge
  • --enable-multibyte
  • --enable-rubyinterp
  • --enable-pythoninterp
  • --enable-perlinterp
  • --enable-luainterp
  • --enable-gui=gtk2
  • --enable-cscope

Note that it's written for anything Debian-like. See the original walkthrough for help with other distros.

#! /bin/bash
# Description:
# Compile a full-featured Vim from source on Ubuntu/Debian distros. Based
# entirely on
# https://github.com/Valloric/YouCompleteMe/wiki/Building-Vim-from-source
#
# Use:
# ./compile_full_vim.sh
main(){
echo "y" | sudo apt-get remove \
vim \
vim-runtime \
gvim \
vim-tiny \
vim-common \
vim-gui-common
echo "y" | sudo apt-get install \
libncurses5-dev \
libgnome2-dev \
libgnomeui-dev \
libgtk2.0-dev \
libatk1.0-dev \
libbonoboui2-dev \
libcairo2-dev \
libx11-dev \
libxpm-dev \
libxt-dev \
python-dev ruby-dev \
mercurial
cd ~
hg clone https://code.google.com/p/vim/
cd vim
./configure --with-features=huge \
--enable-multibyte \
--enable-rubyinterp \
--enable-pythoninterp \
--with-python-config-dir=/usr/lib/python2.7/config \
--enable-perlinterp \
--enable-luainterp \
--enable-gui=gtk2 \
--enable-cscope \
--prefix=/usr
make VIMRUNTIMEDIR=/usr/share/vim/vim74
sudo make install
}
main
@xahon

This comment has been minimized.

Copy link

xahon commented Sep 16, 2018

git clone git@github.com:vim/vim.git --depth=1

@Hitlrsociety420

This comment has been minimized.

Copy link

Hitlrsociety420 commented Oct 6, 2019

You can use omni complete if you don't enable python 3? On your config haven't activated python3.
References https://github.com/ycm-core/YouCompleteMe/wiki/Building-Vim-from-source

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.