Check lsp client is active for all language files (#790)

This commit is contained in:
hui.liu 2021-07-09 00:35:41 +08:00 committed by GitHub
parent 9233611bdc
commit 53fed9d655
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
33 changed files with 412 additions and 291 deletions

View file

@ -1,10 +1,13 @@
-- npm install -g vscode-css-languageserver-bin
require("lspconfig").cssls.setup {
cmd = {
"node",
DATA_PATH .. "/lspinstall/css/vscode-css/css-language-features/server/dist/node/cssServerMain.js",
"--stdio",
},
on_attach = require("lsp").common_on_attach,
}
if not require("lv-utils").check_lsp_client_active "cssls" then
-- npm install -g vscode-css-languageserver-bin
require("lspconfig").cssls.setup {
cmd = {
"node",
DATA_PATH .. "/lspinstall/css/vscode-css/css-language-features/server/dist/node/cssServerMain.js",
"--stdio",
},
on_attach = require("lsp").common_on_attach,
}
end
vim.cmd "setl ts=2 sw=2"