-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
23 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
local lsp_installer = require("nvim-lsp-installer") | ||
local lsp_config = require("lspconfig") | ||
|
||
local servers = { "sumneko_lua" } | ||
|
||
lsp_installer.setup { | ||
ensure_installed = servers | ||
} | ||
|
||
|
||
for _, server in pairs(servers) do | ||
local opts = { | ||
on_attach = require("user.lsp.handlers").on_attach, | ||
capabilities = require("user.lsp.handlers").capabilities, | ||
} | ||
local has_custom_opts, server_custom_opts = pcall(require, "user.lsp.settings." .. server) | ||
if has_custom_opts then | ||
opts = vim.tbl_deep_extend("force", server_custom_opts, opts) | ||
end | ||
lsp_config[server].setup(opts) | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
require "lspconfig" | ||
require "user.lsp.lsp-installer" | ||
|
||
require "user.lsp.configs" | ||
require "user.lsp.null-ls" |
This file was deleted.
Oops, something went wrong.