summaryrefslogtreecommitdiff
path: root/script/workspace/workspace.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2022-12-17 03:47:53 +0800
committer最萌小汐 <sumneko@hotmail.com>2022-12-17 03:47:53 +0800
commit7075ca19746addabc66296518a1eeafca8144723 (patch)
tree17b070aab64d6f1e07ba26024a66eb959c9c9f11 /script/workspace/workspace.lua
parentc3b468fd4a6d745c77340eb71c0950d221a6c4ba (diff)
downloadlua-language-server-7075ca19746addabc66296518a1eeafca8144723.zip
update filewatch
Diffstat (limited to 'script/workspace/workspace.lua')
-rw-r--r--script/workspace/workspace.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/script/workspace/workspace.lua b/script/workspace/workspace.lua
index b6be6fc5..bf4256b3 100644
--- a/script/workspace/workspace.lua
+++ b/script/workspace/workspace.lua
@@ -308,7 +308,7 @@ function m.awaitPreload(scp)
if scp.uri and not scp:get('bad root') then
log.info('Scan files at:', scp:getName())
- scp:gc(fw.watch(m.normalize(furi.decode(scp.uri))))
+ scp:gc(fw.watch(m.normalize(furi.decode(scp.uri)), true))
local count = 0
---@async
native:scan(furi.decode(scp.uri), function (path)
@@ -326,7 +326,7 @@ function m.awaitPreload(scp)
for _, libMatcher in ipairs(librarys) do
log.info('Scan library at:', libMatcher.uri)
local count = 0
- scp:gc(fw.watch(furi.decode(libMatcher.uri)))
+ scp:gc(fw.watch(furi.decode(libMatcher.uri), true))
scp:addLink(libMatcher.uri)
---@async
libMatcher.matcher:scan(furi.decode(libMatcher.uri), function (path)