summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2018-11-14 22:30:05 +0800
committerruki <[email protected]>2018-11-14 09:00:30 +0800
commit2f4297339f80b749512f1cb9335abc236dd4c5d4 (patch)
treef7307ea060df0a1a9aa90922c826c89c149014f1
parent7d234801498d6e272d780407695ebff89a64d675 (diff)
fix update bug on linux
-rw-r--r--xmake/actions/update/main.lua10
1 files changed, 6 insertions, 4 deletions
diff --git a/xmake/actions/update/main.lua b/xmake/actions/update/main.lua
index 4bcc334be..6981d2231 100644
--- a/xmake/actions/update/main.lua
+++ b/xmake/actions/update/main.lua
@@ -251,10 +251,12 @@ function main()
end
-- cannot support to update dev/master on windows
- if is_host("windows") and not version:find('.', 1, true) then
- raise("not support to update %s on windows!", version)
- else
- mainurls = {format("https://github.com/tboox/xmake/releases/download/%s/xmake-%s.exe", version, version)}
+ if is_host("windows") then
+ if version:find('.', 1, true) then
+ mainurls = {format("https://github.com/tboox/xmake/releases/download/%s/xmake-%s.exe", version, version)}
+ else
+ raise("not support to update %s on windows!", version)
+ end
end
-- trace