diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2024-06-05 17:44:09 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2024-06-05 17:44:09 +0800 |
commit | 74134c9d90f708bb99e7ee80df459738286fa2f3 (patch) | |
tree | 2d8ee36770f9fc257f51608a69baa4d8ee46f2ce | |
parent | 32c117e45d643cbcc6679d1574ec76bde17cbaeb (diff) | |
download | lua-language-server-74134c9d90f708bb99e7ee80df459738286fa2f3.zip |
Revert "适配 bee.sys"
This reverts commit c59bd7f4765a8016dfbbf3c8c9879387ca86acfd.
-rw-r--r-- | script/files.lua | 3 | ||||
-rw-r--r-- | script/filewatch.lua | 3 | ||||
-rw-r--r-- | script/meta/bee/filesystem.lua | 7 | ||||
-rw-r--r-- | script/meta/bee/filewatch.lua | 2 | ||||
-rw-r--r-- | script/meta/bee/socket.lua | 2 | ||||
-rw-r--r-- | script/meta/bee/sys.lua | 13 | ||||
-rw-r--r-- | script/meta/bee/thread.lua | 2 |
7 files changed, 11 insertions, 21 deletions
diff --git a/script/files.lua b/script/files.lua index 68c3b8a5..b9df5695 100644 --- a/script/files.lua +++ b/script/files.lua @@ -1,6 +1,5 @@ local platform = require 'bee.platform' local fs = require 'bee.filesystem' -local sys = require 'bee.sys' local config = require 'config' local glob = require 'glob' local furi = require 'file-uri' @@ -71,7 +70,7 @@ local function getRealParent(path) == path :string():gsub('^%w+:', string.lower) then return path end - local res = sys.fullpath(path) + local res = fs.fullpath(path) return getRealParent(parent) / res:filename() end diff --git a/script/filewatch.lua b/script/filewatch.lua index 7fb3e605..6520afe6 100644 --- a/script/filewatch.lua +++ b/script/filewatch.lua @@ -1,7 +1,6 @@ local fw = require 'bee.filewatch' local fs = require 'bee.filesystem' local plat = require 'bee.platform' -local sys = require 'bee.sys' local await = require 'await' local files = require 'files' @@ -17,7 +16,7 @@ local function isExists(filename) if plat.os ~= 'windows' then return true end - local res = sys.fullpath(path) + local res = fs.fullpath(path) if not res then return false end diff --git a/script/meta/bee/filesystem.lua b/script/meta/bee/filesystem.lua index 2a353065..0c7e41a8 100644 --- a/script/meta/bee/filesystem.lua +++ b/script/meta/bee/filesystem.lua @@ -1,4 +1,4 @@ ----@meta bee.filesystem +---@meta ---@class fs.path ---@operator div: fs.path @@ -75,6 +75,11 @@ end ---@param path fs.path ---@return fs.path +function fs.fullpath(path) +end + +---@param path fs.path +---@return fs.path function fs.absolute(path) end diff --git a/script/meta/bee/filewatch.lua b/script/meta/bee/filewatch.lua index 813548b2..b5211355 100644 --- a/script/meta/bee/filewatch.lua +++ b/script/meta/bee/filewatch.lua @@ -1,4 +1,4 @@ ----@meta bee.filewatch +---@meta ---@class bee.filewatch.instance local instance = {} diff --git a/script/meta/bee/socket.lua b/script/meta/bee/socket.lua index b5e3a7b2..55c349a6 100644 --- a/script/meta/bee/socket.lua +++ b/script/meta/bee/socket.lua @@ -1,4 +1,4 @@ ----@meta bee.socket +---@meta ---@alias bee.socket.protocol ---| 'tcp' diff --git a/script/meta/bee/sys.lua b/script/meta/bee/sys.lua deleted file mode 100644 index ad14702c..00000000 --- a/script/meta/bee/sys.lua +++ /dev/null @@ -1,13 +0,0 @@ ----@meta bee.sys - ----@class bee.sys -local sys = {} - ----@param path fs.path ----@return fs.path -function sys.fullpath(path) end - ----@return fs.path -function sys.exe_path() end - -return sys diff --git a/script/meta/bee/thread.lua b/script/meta/bee/thread.lua index 15955aff..1691d49a 100644 --- a/script/meta/bee/thread.lua +++ b/script/meta/bee/thread.lua @@ -1,4 +1,4 @@ ----@meta bee.thread +---@meta ---@class bee.thread local thread = {} |