aboutsummaryrefslogtreecommitdiffstats
path: root/lua
diff options
context:
space:
mode:
Diffstat (limited to 'lua')
-rw-r--r--lua/nvim-lsp-installer/servers/init.lua1
-rw-r--r--lua/nvim-lsp-installer/servers/puppet/init.lua22
2 files changed, 23 insertions, 0 deletions
diff --git a/lua/nvim-lsp-installer/servers/init.lua b/lua/nvim-lsp-installer/servers/init.lua
index f0ed0533..1b91a30a 100644
--- a/lua/nvim-lsp-installer/servers/init.lua
+++ b/lua/nvim-lsp-installer/servers/init.lua
@@ -69,6 +69,7 @@ local CORE_SERVERS = Data.set_of {
"ocamlls",
"omnisharp",
"prismals",
+ "puppet",
"purescriptls",
"pylsp",
"pyright",
diff --git a/lua/nvim-lsp-installer/servers/puppet/init.lua b/lua/nvim-lsp-installer/servers/puppet/init.lua
new file mode 100644
index 00000000..f69757c5
--- /dev/null
+++ b/lua/nvim-lsp-installer/servers/puppet/init.lua
@@ -0,0 +1,22 @@
+local path = require "nvim-lsp-installer.path"
+local server = require "nvim-lsp-installer.server"
+local context = require "nvim-lsp-installer.installers.context"
+local std = require "nvim-lsp-installer.installers.std"
+
+return function(name, root_dir)
+ return server.Server:new {
+ name = name,
+ root_dir = root_dir,
+ installer = {
+ context.github_release_file("puppetlabs/puppet-editor-services", function(version)
+ return ("puppet_editor_services_%s.zip"):format(version)
+ end),
+ context.capture(function(ctx)
+ return std.unzip_remote(ctx.github_release_file)
+ end),
+ },
+ default_options = {
+ cmd = { path.concat { root_dir, "puppet-languageserver" }, "--stdio" },
+ },
+ }
+end