How to configure and install vim from source?

Vim 8.0 has been released some weeks ago and maybe you want to install it. Sometimes, binaries in packages are often not up-to-date or not configured with python. Here the command to install it from source with python et python3 options (useful if you use YouCompleteMe):

git clone
cd vim
./configure --enable-pythoninterp --enable-python3interp
sudo make install

You can also add other options. You can list them with:

./configure --help

Personally, I use the following flags

./configure --with-features=huge \
            --enable-multibyte \
            --enable-rubyinterp=yes \
            --enable-pythoninterp=yes \
            --enable-python3interp=yes \
            --enable-perlinterp=yes \
            --enable-luainterp=yes \
            --enable-gui=gtk2 \
            --enable-cscope \

where $INSTALL_COMPILED_DIRECTORY is another directory in my home where the binaries will be installed instead of /usr. In this case, I don’t need to use sudo and it doesn’t affect the standard installation of vim.