Shougo / ddc-source-lsp

lsp source for ddc.vim
Other
66 stars 20 forks source link

Question about usage #36

Closed jeffwillette closed 1 year ago

jeffwillette commented 1 year ago

Hi. What is the suggested way to start the lsp for using this as a source?

For example, I have been trying to get this plugin to work with https://github.com/prabirshrestha/vim-lsp, as this old post about deoplete seems to indicate would work (https://jdhao.github.io/2020/11/04/replace_deoplete_jedi_for_LSP/)

Is ddc-source-nvim-lsp compatible with the above plugin, or should the lsp be started in some other way?

Shougo commented 1 year ago

If you use vim-lsp, you should use it instead.

https://github.com/shun/ddc-vim-lsp

ddc-source-nvim-lsp is for nvim-lsp. It is neovim only.

Shougo commented 1 year ago
set nocompatible
set runtimepath+=~/work/denops.vim
set runtimepath+=~/work/ddc.vim
set runtimepath+=~/work/ddc-around
set runtimepath+=~/work/ddc-matcher_head
set runtimepath+=~/work/ddc-sorter_rank
set runtimepath+=~/work/ddc-nvim-lsp
set runtimepath+=~/src/nvim-lspconfig

call ddc#custom#patch_global('sources', ['around', 'nvim-lsp'])

call ddc#custom#patch_global('sourceOptions', {
      \ '_': {
      \   'matchers': ['matcher_head'],
      \   'sorters': ['sorter_rank']},
      \ })

call ddc#enable()

lua require'lspconfig'.pylsp.setup{}
jeffwillette commented 1 year ago

Thanks for the info and the example. That would have taken me a long time to figure out on my own. It works great now