25 lines
645 B
Lua
25 lines
645 B
Lua
return {
|
|
-- Recognized filetypes for C#
|
|
filetypes = { "cs", "vb" },
|
|
|
|
-- Root directory detection: looks for .sln, .csproj, or version control folders
|
|
root_dir = function(fname)
|
|
local util = require("lspconfig.util")
|
|
return util.root_pattern("*.sln")(fname)
|
|
or util.root_pattern("*.csproj")(fname)
|
|
or util.root_pattern(".git", ".hg")(fname)
|
|
or util.path.dirname(fname)
|
|
end,
|
|
|
|
-- Additional settings for csharp_ls (expand as needed)
|
|
settings = {
|
|
csharp = {
|
|
formatting = {
|
|
enable = true, -- Enable formatting if supported
|
|
},
|
|
-- Add further csharp_ls settings here
|
|
},
|
|
},
|
|
}
|
|
|