diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2021-10-11 20:20:40 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2021-10-11 20:20:40 +0800 |
commit | 75dfbf821c68ab907957febc38b09d1a5b7fe449 (patch) | |
tree | 04a646aac75d84c2a90262d29244718d7f96de35 /make | |
parent | fce3ee4e44de05bb59aed12accdd7d5f8de9e8fa (diff) | |
download | lua-language-server-75dfbf821c68ab907957febc38b09d1a5b7fe449.zip |
pass tests
Diffstat (limited to 'make')
-rw-r--r-- | make/bootstrap.lua | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/make/bootstrap.lua b/make/bootstrap.lua index b29fa03e..34e8a363 100644 --- a/make/bootstrap.lua +++ b/make/bootstrap.lua @@ -1,5 +1,6 @@ local args = {}
-local main = 'main.lua'
+local sep = package.config:sub(1,1)
+local main = '.' .. sep .. 'main.lua'
local i = 1
while arg[i] do
@@ -17,11 +18,11 @@ while arg[i] do end
local root; do
- local sep = package.config:sub(1,1)
- if sep == '\\' then
- sep = '/\\'
+ local sepp = sep
+ if sepp == '\\' then
+ sepp = '/\\'
end
- local pattern = "["..sep.."][^"..sep.."]+"
+ local pattern = "["..sepp.."][^"..sepp.."]+"
root = package.cpath:match("([^;]+)"..pattern..pattern..pattern.."$")
end
|