Skip to content
This repository was archived by the owner on Jul 8, 2021. It is now read-only.
This repository was archived by the owner on Jul 8, 2021. It is now read-only.

Lsp isnt restarted properly (using dein.vim) #2

@aMOPel

Description

@aMOPel

Hey there,
nice plugin, exactly what i need, though im having a little trouble.
Im using dein and it has a little bit of a weird policy for folders. As far as i understood it it has all the repos in ~/.cache/dein/repos/github.com/ and it caches them all together in a cache dir (~/.cache/dein/.cache/init.vim/.dein/), so the rtp of vim isnt as cluttered. Anyway, i did this to setup your plugin:
`" nvim-reload
lua <<EOF
local reload = require('nvim-reload')

local plugin_dirs = os.getenv("HOME") .. '/.cache/dein/.cache/init.vim/.dein/*'

reload.vim_reload_dirs = {
vim.fn.stdpath('config'),
plugin_dirs
}

reload.lua_reload_dirs = {
vim.fn.stdpath('config'),
-- Note: the line below may cause issues reloading your config
plugin_dirs
}
EOF`

i dont know lua but it seems to work? but not quite.
when i do either :Reload or :Restart i get
Client 1 quit with exit code 1 and signal 0 Client 3 quit with exit code 1 and signal 0 Client 5 quit with exit code 1 and signal 0
(called it three times and the client count is increasing by 2 each time)
and also before the restart :LspInfo gives this
`Configured servers: clangd
Neovim logs at: /home/momo/.cache/nvim/lsp.log

1 client(s) attached to this buffer: clangd

Client: clangd (id 1)
root: ..
filetypes: c, cpp, objc, objcpp
cmd: clangd --background-index

1 active client(s):

Client: clangd (id 1)
root: ..
filetypes: c, cpp, objc, objcpp
cmd: clangd --background-index

Clients that match the filetype cpp:

Config: clangd
cmd: clangd --background-index
cmd is executable: True
identified root: ..
custom handlers:
`

and afterwards it gives this
`Configured servers: clangd
Neovim logs at: /home/momo/.cache/nvim/lsp.log

0 client(s) attached to this buffer:

1 active client(s):

Client: clangd (id 3)
root: ..
filetypes: c, cpp, objc, objcpp
cmd: clangd --background-index

Clients that match the filetype cpp:

Config: clangd
cmd: clangd --background-index
cmd is executable: True
identified root: ..
custom handlers:
`

there is some code to restart the lsp in your plugin but it isnt doing it properly for me at least. Any thoughts?

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