aboutsummaryrefslogtreecommitdiffstats
path: root/lua/nvim-lsp-installer/servers/powershell_es/init.lua
diff options
context:
space:
mode:
authorLiza Chevalier <lizalc@pm.me>2021-12-05 14:30:24 -0500
committerGitHub <noreply@github.com>2021-12-05 20:30:24 +0100
commit599e76425afbdae3d5660e89a7c3525263b6f160 (patch)
treee731e8ebd66e0ed53213caab8fb94c4e2c1f2b22 /lua/nvim-lsp-installer/servers/powershell_es/init.lua
parentadd ccls (#299) (diff)
downloadmason-599e76425afbdae3d5660e89a7c3525263b6f160.tar
mason-599e76425afbdae3d5660e89a7c3525263b6f160.tar.gz
mason-599e76425afbdae3d5660e89a7c3525263b6f160.tar.bz2
mason-599e76425afbdae3d5660e89a7c3525263b6f160.tar.lz
mason-599e76425afbdae3d5660e89a7c3525263b6f160.tar.xz
mason-599e76425afbdae3d5660e89a7c3525263b6f160.tar.zst
mason-599e76425afbdae3d5660e89a7c3525263b6f160.zip
fix(powershell_es): don't limit to windows (#311)
Diffstat (limited to 'lua/nvim-lsp-installer/servers/powershell_es/init.lua')
-rw-r--r--lua/nvim-lsp-installer/servers/powershell_es/init.lua17
1 files changed, 10 insertions, 7 deletions
diff --git a/lua/nvim-lsp-installer/servers/powershell_es/init.lua b/lua/nvim-lsp-installer/servers/powershell_es/init.lua
index d138bc57..f95ebcf0 100644
--- a/lua/nvim-lsp-installer/servers/powershell_es/init.lua
+++ b/lua/nvim-lsp-installer/servers/powershell_es/init.lua
@@ -2,7 +2,6 @@ local server = require "nvim-lsp-installer.server"
local path = require "nvim-lsp-installer.path"
local std = require "nvim-lsp-installer.installers.std"
local context = require "nvim-lsp-installer.installers.context"
-local installers = require "nvim-lsp-installer.installers"
return function(name, root_dir)
return server.Server:new {
@@ -10,13 +9,17 @@ return function(name, root_dir)
root_dir = root_dir,
homepage = "https://github.com/PowerShell/PowerShellEditorServices",
languages = { "powershell" },
- installer = installers.when {
- win = {
- context.use_github_release_file("PowerShell/PowerShellEditorServices", "PowerShellEditorServices.zip"),
- context.capture(function(ctx)
- return std.unzip_remote(ctx.github_release_file)
- end),
+ installer = {
+ std.ensure_executables {
+ {
+ "pwsh",
+ "pwsh was not found in path. Refer to https://github.com/PowerShell/PowerShell#get-powershell for instructions.",
+ },
},
+ context.use_github_release_file("PowerShell/PowerShellEditorServices", "PowerShellEditorServices.zip"),
+ context.capture(function(ctx)
+ return std.unzip_remote(ctx.github_release_file)
+ end),
},
default_options = {
bundle_path = path.concat { root_dir },