diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2020-09-23 16:05:54 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2020-09-23 16:05:54 +0800 |
commit | 57bfae9cd5a176c68f5874f8dad47db4f9e29174 (patch) | |
tree | becbfdf6b37f4926ef89ab6e613b59ca5925089d /main-beta.lua | |
parent | dc1a5bb4215a32ad16697b48d74585242c685217 (diff) | |
download | lua-language-server-57bfae9cd5a176c68f5874f8dad47db4f9e29174.zip |
修正以`main.lua`为参数启动时,路径计算错误的bug
Diffstat (limited to 'main-beta.lua')
-rw-r--r-- | main-beta.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/main-beta.lua b/main-beta.lua index bdef0b6b..0f52e962 100644 --- a/main-beta.lua +++ b/main-beta.lua @@ -1,6 +1,6 @@ local currentPath = debug.getinfo(1, 'S').source:sub(2) local rootPath = currentPath:gsub('[/\\]*[^/\\]-$', '') -loadfile(rootPath .. '/platform.lua')('script-beta') +loadfile((rootPath == '' and '.' or rootPath) .. '/platform.lua')('script-beta') local fs = require 'bee.filesystem' ROOT = fs.path(rootPath) LANG = LANG or 'en-US' |