From 78d4336b677292747a6f7f06071c1f0eb5af4a53 Mon Sep 17 00:00:00 2001
From: Sergey Matveev <stargrave@stargrave.org>
Date: Tue, 11 Jan 2022 20:50:34 +0300
Subject: [PATCH] Enable pyls only if it exists

clangd and gopls are globally installed. pyls lives in venv.
---
 vim/.vim/ftplugin/python/lsp.vim | 3 +++
 vim/.vim/plugin/lsp.vim          | 1 +
 2 files changed, 4 insertions(+)
 create mode 100644 vim/.vim/ftplugin/python/lsp.vim

diff --git a/vim/.vim/ftplugin/python/lsp.vim b/vim/.vim/ftplugin/python/lsp.vim
new file mode 100644
index 0000000..cd34fa5
--- /dev/null
+++ b/vim/.vim/ftplugin/python/lsp.vim
@@ -0,0 +1,3 @@
+if executable("pyls")
+    LSClientEnable
+endif
diff --git a/vim/.vim/plugin/lsp.vim b/vim/.vim/plugin/lsp.vim
index 532b5e0..7b6d4ea 100644
--- a/vim/.vim/plugin/lsp.vim
+++ b/vim/.vim/plugin/lsp.vim
@@ -14,6 +14,7 @@ let g:lsc_server_commands = {
     \             "mccabe": {"enabled": v:false},
     \         },
     \     }},
+    \     "enabled": v:false,
     \ },
 \ }
 let g:lsc_auto_map = {
-- 
2.51.0