我正在尝试在vim7.3中完成python的代码。安装vim时,我使用以下配置:
./configure --prefix=${HOME}/vim73 --enable-python3interp=yes --with-python3-config-dir=/home/etobkru/Python3/lib/python3.1/config
make && make install
我复制这个文件:
http://vim.cybermirror.org/runtime/autoload/python3complete.vim
在~/vim73/share/vim/vim73/autoload/
目录和此文件中:
./share/vim/vim73/ftplugin/python.vim
我改变了
到
setlocal omnifunc=python3complete#Complete.
但当我按<c-x, c-o>
时,我收到一条错误消息:
Error: Required vim compiled with +python3
E117: Unknown function: python3complete#Complete
如果我写:python3
我会得到
E319: Sorry, the command is not available in this version
这取决于您的vim版本和OS如何提供Python和Python3,以及Python和Python3是否同时受支持。否则,如果编译了,那么您第一次使用的Python版本将被激活。在
检查以下线程和从那里链接的线程: Vim 7.3: Python3 support
删除任何自动完成尝试并忘记您的问题,安装neocomplcache(script site)
我遇到了和你完全相同的问题,这个脚本解决了我所有的自动完成需求,它的功能非常丰富,你不会注意到它在那里,直到你需要它。在
相关问题 更多 >
编程相关推荐