diff options
| author | Jérôme Leclercq <[email protected]> | 2025-10-08 00:02:36 +0200 |
|---|---|---|
| committer | GitHub <[email protected]> | 2025-10-08 00:02:36 +0200 |
| commit | fde70095c345a401f9c7843a8f2c33b2e227a807 (patch) | |
| tree | 1c334dd7795b2442dc4463f5fc365e372075705f | |
| parent | 8bcc3569cba28654540fdca7a3954b814fae6ac6 (diff) | |
package download: don't get submodules if disabled
| -rw-r--r-- | xmake/modules/private/action/require/impl/actions/download.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/xmake/modules/private/action/require/impl/actions/download.lua b/xmake/modules/private/action/require/impl/actions/download.lua index 25c9d1b56..02585b70c 100644 --- a/xmake/modules/private/action/require/impl/actions/download.lua +++ b/xmake/modules/private/action/require/impl/actions/download.lua @@ -130,7 +130,8 @@ function _checkout(package, url, sourcedir, opt) -- only shallow clone this tag -- @see https://github.com/xmake-io/xmake/issues/4151 if tag and git.clone.can_clone_tag() then - git.clone(url, {depth = 1, recursive = true, shallow_submodules = true, longpaths = longpaths, branch = tag, outputdir = packagedir}) + local clone_submodules = opt.url_submodules ~= false + git.clone(url, {depth = 1, recursive = clone_submodules, shallow_submodules = clone_submodules, longpaths = longpaths, branch = tag, outputdir = packagedir}) else -- clone whole history and tags |
