diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2018-12-13 12:19:33 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2018-12-13 12:19:33 +0800 |
commit | 11004db9fc51a552107ae6d54fbaef8f37694e2f (patch) | |
tree | a9f5756e36e56054c8b01f80f371658a437ec738 /server/publish.lua | |
parent | ea14e06ff09bd1ddd574923d0fbd57958ff540b8 (diff) | |
download | lua-language-server-11004db9fc51a552107ae6d54fbaef8f37694e2f.zip |
跳过不存在的文件
Diffstat (limited to 'server/publish.lua')
-rw-r--r-- | server/publish.lua | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/server/publish.lua b/server/publish.lua index 5871bbec..76d36472 100644 --- a/server/publish.lua +++ b/server/publish.lua @@ -27,7 +27,9 @@ local function copyFiles(out) local function copy(relative, mode) local source = EXTENSION / relative local target = out / relative - assert(fs.exists(source)) + if not fs.exists(source) then + return + end if fs.is_directory(source) then fs.create_directory(target) if mode == true then |