Skip to content

lsp#complete omnifunc isn't triggered #285

@kmARC

Description

@kmARC

Omnifunc completion works very nicely with the css completer:

let g:completor_css_omni_trigger = '([\w-]+|@[\w-]*|[\w-]+:\s*[\w-]*)$'

I would love to use the omnifunc completer from prabirshrestha/vim-lsp, however, It is not listing matches.

My configuration is similar to the css completion, I tried it with bash-language-server.

set omnifunc=lsp#complete
let g:completor_sh_omni_trigger = '(\w*)$'

The debug log shows that - supposedly - the omnifunc is called:

2020-02-23 08:45:50,912 [INFO][.../completor.vim/pythonx/completers/common/omni.py] omnifunc: b'lsp#complete'
2020-02-23 08:45:50,913 [INFO][.../completor.vim/pythonx/completers/common/omni.py] start: 9,0

If I press i_Ctrl-X_Ctrl_O, the completion popup appears, the omnifunc is working.


I understand that completor itself could be configured to use LSP directly, however, vim-lsp (with mattn/vim-lsp-settings) is a super nice and scalable solution to maintain LSP enginges easily.

I could also use the suggested prabirshrestha/asyncomplete.vim and prabirshrestha/asyncomplete-lsp.vim async engines, however completor gives a more configurable and nicer representation, and better configurability for triggers etc.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions