- iOS/Objective-C 元类和类别
- objective-c - -1001 错误,当 NSURLSession 通过 httpproxy 和/etc/hosts
- java - 使用网络类获取 url 地址
- ios - 推送通知中不播放声音
我正在为 C++ 设置 YouCompleteMe,但是当我打开一个 .cpp 文件时,我收到错误 NoExtraConfDetected:未检测到 .ycm_extra_conf.py 文件
.vimrc 文件如下所示:
set nocompatible " be iMproved, required filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
"call vundle#begin('~/some/path/here')
" let Vundle manage Vundle, required
Plugin 'VundleVim/Vundle.vim'
Plugin 'rdnetto/YCM-Generator'
Plugin 'Valloric/YouCompleteMe'
let g:ycm_global_ycm_extra_conf = '$USER/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm/.ycm_extra_conf.py'
" All of your Plugins must be added before the following line
call vundle#end() " required
filetype plugin indent on " required
我认为这一行:
let g:ycm_global_ycm_extra_conf = '$USER/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm/.ycm_extra_conf.py'
会处理错误。
我沿着路径走,.ycm_extra_conf.py 就在那里。
我是否将 let g:ycm_global_ycm_extra_conf = '$USER/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm/.ycm_extra_conf.py' 放置在 .vimrc 文件中?
最佳答案
无法解释,但 vimrc 不喜欢 $USER,你需要那里的完整路径,比如 $HOME。试试这个:
让 g:ycm_global_ycm_extra_conf = '/home/YOUR_USER/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm/.ycm_extra_conf.py'
关于c++ - VIM YouCompleteMe 错误 - NoExtraConfDetected : No . 检测到 ycm_extra_conf.py 文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47812854/
我为 VIM 安装了 YCM 和 syntastic,通常它们工作正常,但是当它检测到我的代码中的一些错误时我遇到了问题,它显示找不到一些头文件(这是我的项目头文件)。 我的目录树如下所示: TOP
我目前正在将基于 C++ 的 IDE 从 XCode 切换到 Vim。我一直在阅读有关 Vim 插件“YCM”的信息,它需要在源目录中存在 .ycm_extra_conf.py。我正在使用 YCM G
我已经有了带有 YouCompleteMe 插件的 Vim(编译时带有对 C 系列语言的语义支持),我将其用于 Python 等。现在我想用 C 尝试一下(我以前从未用 C 开发过,所以我对一些细节有
我正在为 C++ 设置 YouCompleteMe,但是当我打开一个 .cpp 文件时,我收到错误 NoExtraConfDetected:未检测到 .ycm_extra_conf.py 文件 .vi
我是一名优秀的程序员,十分优秀!