BundleInstall,默認會出現錯誤
ycm_client_support.[so|pyd|dll] and ycm_core.[so|pyd|dll] not detected; you need to compile YCM before using it. Read the docs!
最簡單解決方式:
cd ~/.vim/bundle/YouCompleteMe ./install.sh --clang-completer
另外,vimConfig/plugin/youCompleteMe-setting.vim
1 """"""""""""YCM"""""""""""""""""""" 2 let g:ycm_global_ycm_extra_conf = '~/.vim/bundle/YouCompleteMe/cpp/ycm/.ycm_extra_conf.py' 3 let g:ycm_collect_identifiers_from_tags_files = 1 4 let g:ycm_seed_identifiers_with_syntax = 1 5 let g:ycm_confirm_extra_conf = 0
添加自定義頭文件路徑
修改~/.vim/bundle/YouCompleteMe/cpp/ycm/.ycm_extra_conf.py
在 “flags = [ ” 后面加上兩行:
'-isystem', '你的路徑',
注意,路徑不能用~/aaaa,要全路徑,否則找不到。