diff options
author | Christian Chiarulli <[email protected]> | 2021-07-13 21:13:55 -0400 |
---|---|---|
committer | GitHub <[email protected]> | 2021-07-13 21:13:55 -0400 |
commit | a097fa4c04e6db34bb409e0dea302c20629da8ec (patch) | |
tree | fb1c5bdd14cac82a363ea6c25b03a475050305f2 /ftplugin/sh.lua | |
parent | 04f9f53914a7dd999117ed73c5fa0ab3b0dc95e4 (diff) |
LunarVim 0.4.8 (#919)0.4.8
Diffstat (limited to 'ftplugin/sh.lua')
-rw-r--r-- | ftplugin/sh.lua | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/ftplugin/sh.lua b/ftplugin/sh.lua index c299f2de..54002f19 100644 --- a/ftplugin/sh.lua +++ b/ftplugin/sh.lua @@ -1,3 +1,17 @@ +O.formatters.filetype["sh"] = { + function() + return { + exe = O.lang.sh.formatter.exe, + args = O.lang.sh.formatter.args, + stdin = not (O.lang.sh.formatter.stdin ~= nil), + } + end, +} + +require("formatter.config").set_defaults { + logging = false, + filetype = O.formatters.filetype, +} if not require("lv-utils").check_lsp_client_active "bashls" then -- npm i -g bash-language-server require("lspconfig").bashls.setup { @@ -26,6 +40,7 @@ if not require("lv-utils").check_lsp_client_active "efm" then -- init_options = {initializationOptions}, cmd = { DATA_PATH .. "/lspinstall/efm/efm-langserver" }, init_options = { documentFormatting = true, codeAction = false }, + root_dir = require("lspconfig").util.root_pattern ".git/", filetypes = { "sh" }, settings = { rootMarkers = { ".git/" }, |