简体   繁体   English

代码完成无法在Vim中用于ruby

[英]Code completion not working in vim for ruby

I am using mvim on Mac for programming in Ruby and have installed the rcodetools plugin for vim. 我在Mac上使用mvim进行Ruby编程,并且已经为vim安装了rcodetools插件。 On doing a CX CU i get the message completefunc is not set. 在执行CX CU时,我未设置消息completefunc。 I havent been able to figure out what completefunc should be set to. 我还不能弄清楚应该将completefunc设置为什么。 Any suggestions? 有什么建议么?

The completefunc setting should get set automatically to "RCT_completion" in rcodetools.vim: 在rcodetools.vim中, completefunc设置应自动设置为“ RCT_completion”:

if v:version >= 700
    execute "au Filetype ruby setlocal completefunc=" . s:sid . "RCT_completion"
endif

It sounds like the filetype of the buffer you're editing might not be "ruby". 听起来您正在编辑的缓冲区的文件类型可能不是“红宝石”。
You can check this by running the :set ft? 您可以通过运行:set ft?进行检查:set ft? command 命令

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM