Skip to content

Commit 8dd37a6

Browse files
committed
fix invalid path
1 parent 9216042 commit 8dd37a6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

xmake/core/package/package.lua

+2-2
Original file line numberDiff line numberDiff line change
@@ -785,7 +785,7 @@ function _instance:cachedir()
785785
local version_str = self:version_str()
786786
-- strip invalid characters on windows, e.g. `>= <=`
787787
if os.is_host("windows") then
788-
version_str = version_str:gsub("[>=<]", "")
788+
version_str = version_str:gsub("[>=<|%*]", "")
789789
end
790790
if self:is_local() then
791791
cachedir = path.join(config.buildir({absolute = true}), ".packages", name:sub(1, 1):lower(), name, version_str, "cache")
@@ -814,7 +814,7 @@ function _instance:installdir(...)
814814
if version_str then
815815
-- strip invalid characters on windows, e.g. `>= <=`
816816
if os.is_host("windows") then
817-
version_str = version_str:gsub("[>=<]", "")
817+
version_str = version_str:gsub("[>=<|%*]", "")
818818
end
819819
installdir = path.join(installdir, version_str)
820820
end

0 commit comments

Comments
 (0)