From 5def1345ff87787c75f10a127a361fa5a263db25 Mon Sep 17 00:00:00 2001 From: Tony Blyler Date: Fri, 11 Aug 2017 09:43:25 -0400 Subject: [PATCH] Update ycm postinstall hook to enforce python3 if possible --- home/.config/nvim/init.vim | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/home/.config/nvim/init.vim b/home/.config/nvim/init.vim index 5648b63..9130084 100644 --- a/home/.config/nvim/init.vim +++ b/home/.config/nvim/init.vim @@ -13,7 +13,12 @@ endfunction call plug#begin($HOME.'/.nvim/plugged') if s:uname == "Linux" - Plug 'Valloric/YouCompleteMe', { 'do': './install.py --all' } + " enforce python3 for distros like debian where python2 is the default + if has('python3') + Plug 'Valloric/YouCompleteMe', { 'do': 'python3 install.py --all' } + else + Plug 'Valloric/YouCompleteMe', { 'do': './install.py --all' } + endif else " OSX is terrible about everything nice Plug 'Valloric/YouCompleteMe', { 'do': './install.py --clang-completer --gocode-completer --racer-completer --tern-completer' }