Add fennel-language-server

This commit is contained in:
Alexander Rosenberg 2022-11-30 08:32:01 -08:00
parent 5bcd29c32a
commit 5712ae18c2
Signed by: Zander671
GPG Key ID: 5FD0394ADBD72730

View File

@ -491,6 +491,7 @@
"/")
":p") joined_path)))
(let [lsp (require :lspconfig)
configs (require :lspconfig.configs)
lsp_cap ((. (require :cmp_nvim_lsp) :default_capabilities))]
(macro setup_server! [name ...]
(let [opts { :on_attach `_G.zander.lsp_on_attach
@ -518,7 +519,20 @@
:checkThirdParty false
:library (vim.api.nvim_get_runtime_file "" true) }
:telemetry {
:enable false }}})))
:enable false }}})
(tset configs :fennel_language_server {
:default_config {
:cmd [ "fennel-language-server" ]
:filetypes [ "fennel" ]
:single_file_support true
:root_dir (lsp.util.root_pattern "fnl")
:settings {
:fennel {
:workspace {
:library (vim.api.nvim_list_runtime_paths) }
:diagnostics {
:globals [ "vim" ] }}}}})
(setup_server! :fennel_language_server)))
(use! :neovim/nvim-lspconfig
:after :cmp-nvim-lsp
:config lsp_config_callback)