Fix problem in workspace for relative directory

This commit is contained in:
Francesco Abbate 2020-12-31 09:09:21 +01:00
parent b37099358e
commit 9e5bf485df
1 changed files with 2 additions and 1 deletions

View File

@ -133,7 +133,8 @@ local function relative_path(ref_dir, dir)
for k = i, #ref_ls do
ups = ups .. "../"
end
return ups .. table.concat(dir_ls, "/", i)
local rel_path = ups .. table.concat(dir_ls, "/", i)
return rel_path ~= "" and rel_path or "."
end