1
- if true then return {} end -- WARN: REMOVE THIS LINE TO ACTIVATE THIS FILE
2
-
3
1
-- AstroLSP allows you to customize the features in AstroNvim's LSP configuration engine
4
2
-- Configuration documentation can be found with `:h astrolsp`
5
3
-- NOTE: We highly recommend setting up the Lua Language Server (`:LspInstall lua_ls`)
@@ -12,16 +10,16 @@ return {
12
10
opts = {
13
11
-- Configuration table of features provided by AstroLSP
14
12
features = {
15
- autoformat = true , -- enable or disable auto formatting on start
16
- codelens = true , -- enable/disable codelens refresh on start
17
- inlay_hints = false , -- enable/disable inlay hints on start
13
+ autoformat = true , -- enable or disable auto formatting on start
14
+ codelens = true , -- enable/disable codelens refresh on start
15
+ inlay_hints = false , -- enable/disable inlay hints on start
18
16
semantic_tokens = true , -- enable/disable semantic token highlighting
19
17
},
20
18
-- customize lsp formatting options
21
19
formatting = {
22
20
-- control auto formatting on save
23
21
format_on_save = {
24
- enabled = true , -- enable or disable format on save globally
22
+ enabled = true , -- enable or disable format on save globally
25
23
allow_filetypes = { -- enable format on save for specified filetypes only
26
24
-- "go",
27
25
},
@@ -40,12 +38,28 @@ return {
40
38
},
41
39
-- enable servers that you already have installed without mason
42
40
servers = {
43
- -- "pyright"
41
+ " docker_compose_language_service" ,
42
+ " dockerls" ,
43
+ " eslint" ,
44
+ " jsonls" ,
45
+ " lua_ls" ,
46
+ " marksman" ,
47
+ " nil_ls" ,
48
+ " pyright" ,
49
+ " ruff" ,
50
+ " rust_analyzer" ,
51
+ " taplo" ,
52
+ " tsserver" ,
53
+ " volar" ,
44
54
},
45
55
-- customize language server configuration options passed to `lspconfig`
46
56
--- @diagnostic disable : missing-fields
47
57
config = {
48
- -- clangd = { capabilities = { offsetEncoding = "utf-8" } },
58
+ nil_ls = {
59
+ formatting = {
60
+ command = { " nixpkgs-fmt" },
61
+ },
62
+ },
49
63
},
50
64
-- customize how language servers are attached
51
65
handlers = {
0 commit comments