From c09c0ebc3a10d045265e1a8c6b9db96d5740abdd Mon Sep 17 00:00:00 2001 From: siduck76 Date: Mon, 26 Apr 2021 13:56:27 +0530 Subject: [PATCH] lspconfig : add bash lsp --- install.sh | 12 +++++++++--- lua/bufferline/lua.lua | 2 -- lua/lspconfig/lua.lua | 2 +- 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/install.sh b/install.sh index a0295e1..5bd9fc8 100755 --- a/install.sh +++ b/install.sh @@ -2,7 +2,7 @@ BASE=$(git rev-parse --show-toplevel) LSP_BIN_PATH=$HOME/.local/bin -default_lsp_langs="css html ts rust python" +default_lsp_langs="css html ts rust python bash" lsp_langs="" choose_langs() { @@ -54,9 +54,9 @@ read -p "which shell do you use?: " shellname echo "$shellname" if [ "$(get_platform)" = "Mac" ]; then - gsed -i "s/bash/$shellname/g" ~/.config/nvim/lua/mappings/lua.lua + gsed -i "s/bash/$shellname/g" ~/.config/nvim/lua/mappings/lua.lua else - sed -i "s/bash/$shellname/g" ~/.config/nvim/lua/mappings/lua.lua + sed -i "s/bash/$shellname/g" ~/.config/nvim/lua/mappings/lua.lua fi echo "shell changed to $shellname on nvim successfully!" @@ -86,6 +86,8 @@ install_node_deps() { sudo npm install -g $@ } +# install languages + install_ts() { install_node_deps typescript typescript-language-server prettier } @@ -113,6 +115,10 @@ install_python() { install_node_deps pyright } +install_bash() { + install_node_deps bash-language-server +} + for lang in ${lsp_langs}; do if fn_exists install_$lang; then heading "Installing $lang language server" diff --git a/lua/bufferline/lua.lua b/lua/bufferline/lua.lua index f708fbc..b77fa93 100644 --- a/lua/bufferline/lua.lua +++ b/lua/bufferline/lua.lua @@ -48,12 +48,10 @@ require "bufferline".setup { guifg = "#282c34", guibg = "#282c34" }, - separator = { guifg = "#1e222a", guibg = "#1e222a" }, - indicator_selected = { guifg = "#1e222a", guibg = "#1e222a" diff --git a/lua/lspconfig/lua.lua b/lua/lspconfig/lua.lua index 0203a9e..f0d7000 100644 --- a/lua/lspconfig/lua.lua +++ b/lua/lspconfig/lua.lua @@ -39,7 +39,7 @@ function on_attach(client) end local lspconf = require "lspconfig" -local servers = {"html", "cssls", "tsserver", "pyright"} +local servers = {"html", "cssls", "tsserver", "pyright" , "bashls"} for k, lang in pairs(servers) do lspconf[lang].setup {