summaryrefslogtreecommitdiff
path: root/script
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2022-08-13 01:23:32 +0800
committer最萌小汐 <sumneko@hotmail.com>2022-08-13 01:23:32 +0800
commit04fa96b7c0abba4d7cca03ed12ff3b65b3912e01 (patch)
treec0c8a2c0e92d0580280f838ba475875c7f82a73c /script
parentc30c5c2e267f6917600afe4f19e1e0d674bad9c6 (diff)
downloadlua-language-server-04fa96b7c0abba4d7cca03ed12ff3b65b3912e01.zip
fix #1431
Diffstat (limited to 'script')
-rw-r--r--script/fs-utility.lua2
-rw-r--r--script/meta/bee/filesystem.lua9
2 files changed, 11 insertions, 0 deletions
diff --git a/script/fs-utility.lua b/script/fs-utility.lua
index b789177c..46e41171 100644
--- a/script/fs-utility.lua
+++ b/script/fs-utility.lua
@@ -620,6 +620,8 @@ function m.fileSync(source, target, option)
return option
end
+---@param dir fs.path
+---@param callback fun(fullPath: fs.path)
function m.scanDirectory(dir, callback)
for fullpath in fs.pairs(dir) do
local status = fs.symlink_status(fullpath):type()
diff --git a/script/meta/bee/filesystem.lua b/script/meta/bee/filesystem.lua
index f6cdff79..cba5ff0e 100644
--- a/script/meta/bee/filesystem.lua
+++ b/script/meta/bee/filesystem.lua
@@ -18,6 +18,10 @@ end
function fsPath:filename()
end
+---@return fs.path
+function fsPath:stem()
+end
+
---@class fs.status
local fsStatus = {}
@@ -88,4 +92,9 @@ end
function fs.copy_file(source, target, options)
end
+---@param oldPath fs.path
+---@param newPath fs.path
+function fs.rename(oldPath, newPath)
+end
+
return fs