summaryrefslogtreecommitdiff
path: root/xmake/modules/private
diff options
context:
space:
mode:
authorruki <[email protected]>2024-08-27 00:29:23 +0800
committerruki <[email protected]>2024-08-27 00:29:23 +0800
commit5aeee42d72b7c2289a0179821db04c36751fc38e (patch)
tree7539dc14bf88551b7e1aad37022ab9768994112b /xmake/modules/private
parente24fa86dbca00fdab06fd7c69ea201f280cfd4e9 (diff)
disable treeless for git #5507
Diffstat (limited to 'xmake/modules/private')
-rw-r--r--xmake/modules/private/action/require/impl/actions/download.lua4
-rw-r--r--xmake/modules/private/utils/statistics.lua2
2 files changed, 3 insertions, 3 deletions
diff --git a/xmake/modules/private/action/require/impl/actions/download.lua b/xmake/modules/private/action/require/impl/actions/download.lua
index 77bd4c55b..fc3045aa2 100644
--- a/xmake/modules/private/action/require/impl/actions/download.lua
+++ b/xmake/modules/private/action/require/impl/actions/download.lua
@@ -96,7 +96,7 @@ function _checkout(package, url, sourcedir, opt)
end
-- only shallow clone this branch
- git.clone(url, {treeless = true, recursive = true, shallow_submodules = true, longpaths = longpaths, branch = branch, outputdir = packagedir})
+ git.clone(url, {depth = 1, recursive = true, shallow_submodules = true, longpaths = longpaths, branch = branch, outputdir = packagedir})
-- download package from revision or tag?
else
@@ -117,7 +117,7 @@ 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, {treeless = true, recursive = true, shallow_submodules = true, longpaths = longpaths, branch = tag, outputdir = packagedir})
+ git.clone(url, {depth = 1, recursive = true, shallow_submodules = true, longpaths = longpaths, branch = tag, outputdir = packagedir})
else
-- clone whole history and tags
diff --git a/xmake/modules/private/utils/statistics.lua b/xmake/modules/private/utils/statistics.lua
index 8273d7af2..6ebe20c13 100644
--- a/xmake/modules/private/utils/statistics.lua
+++ b/xmake/modules/private/utils/statistics.lua
@@ -121,7 +121,7 @@ function main()
{
function ()
import("devel.git.clone")
- clone("https://github.com/xmake-io/xmake-stats.git", {treeless = true, branch = "master", outputdir = outputdir})
+ clone("https://github.com/xmake-io/xmake-stats.git", {depth = 1, branch = "master", outputdir = outputdir})
print("post to traffic ok!")
end
}