summaryrefslogtreecommitdiff
path: root/server
diff options
context:
space:
mode:
Diffstat (limited to 'server')
-rw-r--r--server/publish.lua4
-rw-r--r--server/test.lua4
2 files changed, 6 insertions, 2 deletions
diff --git a/server/publish.lua b/server/publish.lua
index c7cbefcc..f85487e4 100644
--- a/server/publish.lua
+++ b/server/publish.lua
@@ -63,7 +63,9 @@ local function copyFiles(root, out)
end
local function runTest(root)
- local exe = root / 'bin' / 'lua-language-server'
+ local is_macos = package.cpath:sub(-3) == '.so'
+ local ext = is_macos and '' or '.exe'
+ local exe = root / 'bin' / 'lua-language-server' .. ext
local test = root / 'test' / 'main.lua'
local lua = subprocess.spawn {
exe,
diff --git a/server/test.lua b/server/test.lua
index fe2efd23..d39edda4 100644
--- a/server/test.lua
+++ b/server/test.lua
@@ -6,7 +6,9 @@ package.path = (ROOT / 'src' / '?.lua'):string()
.. ';' .. (ROOT / 'src' / '?' / 'init.lua'):string()
local function runTest(root)
- local exe = root / 'bin' / 'lua-language-server'
+ local is_macos = package.cpath:sub(-3) == '.so'
+ local ext = is_macos and '' or '.exe'
+ local exe = root / 'bin' / 'lua-language-server' .. ext
local test = root / 'test' / 'main.lua'
local lua = subprocess.spawn {
exe,