summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2022-03-01 00:06:19 +0800
committerruki <[email protected]>2022-03-01 00:06:19 +0800
commitd35bf537b44745881df92e123d8c99ae79d0ce98 (patch)
tree0563c4dc523927e7670ff93113014690fe8790df
parent2bad6855143f0afbc179688b55cbb695c229165a (diff)
add --system for xrepo fetch
-rw-r--r--xmake/modules/private/xrepo/action/fetch.lua5
1 files changed, 3 insertions, 2 deletions
diff --git a/xmake/modules/private/xrepo/action/fetch.lua b/xmake/modules/private/xrepo/action/fetch.lua
index a1f5b0817..857dd100f 100644
--- a/xmake/modules/private/xrepo/action/fetch.lua
+++ b/xmake/modules/private/xrepo/action/fetch.lua
@@ -40,9 +40,10 @@ function menu_options()
"e.g.",
" - xrepo fetch --configs=\"vs_runtime='MD'\" zlib",
" - xrepo fetch --configs=\"regex=true,thread=true\" boost"},
+ {nil, "system", "k", "false", "Only fetch package on current system."},
{},
{nil, "toolchain", "kv", nil, "Set the toolchain name." },
- {nil, "includes", "kv", nil, "Includes extra lua configuration files.",
+ {nil, "includes", "kv", nil, "Includes extra lua configuration files.",
"e.g.",
" - xrepo fetch -p cross --toolchain=mytool --includes='toolchain1.lua" .. path.envsep() .. "toolchain2.lua'"},
{nil, "deps", "k", nil, "Fetch packages with dependencies." },
@@ -186,7 +187,7 @@ function _fetch_packages(packages)
if #fetchmodes > 0 then
table.insert(require_argv, "--fetch_modes=" .. table.concat(fetchmodes, ','))
end
- local extra = {system = false}
+ local extra = {system = option.get("system")}
if mode == "debug" then
extra.debug = true
end