I just installed Neocomplete and tried it for C files, ruby and python and it works perfectly.
I have problems with vim files as I don't get any omnicompletion at all. I tried C-x C-o and got omnifunc is not set error
What am I doing wrong? I thought this would work from scratch.
You aren't doing anything wrong. It isn't
neocomplete's job to provideomnifunc.Neocomplete does work well with omni completion: it uses
omnifuncto provide good candidates for completion, along with other completions provided by vim. However, neocomplete itself does not provide or setomnifuncfor differnt filetypes. That's why its configuration example has multiple lines withset omnifunc=...It works with python etc. because the corresponding functions are provided by vim runtime files (e.g.
/usr/local/share/vim/vim74/autoload/pythoncomplete.vim) or other plugins (likejedi-vim), and theomnifuncoptions are set accordingly (If you want to know where, try:verbose set omnifunc?).Sadly, no function for omni completion for Vim script is provided by default, so you'll need to i) find one and ii)
set omnifunc=(that function). After that, neocomplete will be able to use that function to provide omni completion.Edit: as @Martin Macak pointed out, neocomplete-vim's github page does show something like omni-completion. After some digging, it seems these completions come from Shougo/neco-vim, mentioned briefly in the doc.
i_CTRL-X_CTRL-Vmentioned there is also worth trying.