我像在官方 nvim lsp 文档中一样安装了 csharp_ls 。我安装了 dotnet-sdk:
$ dotnet --version
5.0.205
以及 csharp-ls:
$ whereis csharp-ls
csharp-ls: /home/user/.dotnet/tools/csharp-ls
但是当我尝试在neovim中运行它时,我得到了这个错误:
:lua require'lspconfig'.csharp_ls.setup{}
E5108: Error executing lua [string ":lua"]:1: attempt to index field 'csharp_ls' (a nil value)
我的 nvim 配置:
call plug#begin('~/.config/nvim/plugged')
Plug 'tpope/vim-fugitive'
Plug 'itchyny/lightline.vim'
Plug 'gruvbox-community/gruvbox'
Plug 'neovim/nvim-lspconfig'
Plug 'hrsh7th/cmp-nvim-lsp'
Plug 'hrsh7th/cmp-buffer'
Plug 'hrsh7th/nvim-cmp'
Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'}
Plug 'nvim-lua/plenary.nvim'
Plug 'nvim-lua/popup.nvim'
Plug 'nvim-telescope/telescope.nvim'
call plug#end()
lua << EOF
require'lspconfig'.tsserver.setup{}
require'lspconfig'.vuels.setup{}
require'lspconfig'.vimls.setup{}
require'lspconfig'.bashls.setup{}
require'lspconfig'.csharp_ls.setup{}
EOF
我在这里想念什么?