You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The problem is that nvim_get_runtime_file returns all neovim runtime directories, including the user config itself. Then when working on one own neovim config, lua_ls sees it kind of twice and outputs a lot of wrong duplicated fields warnings ([duplicate-doc-field]). I suspect this is this issue.
Removing those two directories from the runtime path, makes the issue disappear:
-- lua language server is super confused when editing lua files in the config-- and raises a lot of [duplicate-doc-field] warningslocalruntime_files=vim.api.nvim_get_runtime_file("", true)
fork, vinipairs(runtime_files) doifv=="/home/my-login/.config/nvim/after" orv=="/home/my-login/.config/nvim" thentable.remove(runtime_files, k)
endend...-- library = vim.api.nvim_get_runtime_file("", true) library=runtime_files
The text was updated successfully, but these errors were encountered:
Description
One of the options recommended for
lua_ls
causes issues when working on one own neovim configuration.nvim-lspconfig/doc/server_configurations.md
Lines 6361 to 6362 in 74e1480
The problem is that
nvim_get_runtime_file
returns all neovim runtime directories, including the user config itself. Then when working on one own neovim config,lua_ls
sees it kind of twice and outputs a lot of wrong duplicated fields warnings ([duplicate-doc-field]
). I suspect this is this issue.Removing those two directories from the runtime path, makes the issue disappear:
The text was updated successfully, but these errors were encountered: