diff options
Diffstat (limited to 'xmake/modules/devel/git/clone.lua')
| -rw-r--r-- | xmake/modules/devel/git/clone.lua | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/xmake/modules/devel/git/clone.lua b/xmake/modules/devel/git/clone.lua index bdd02caf1..cc0b8f841 100644 --- a/xmake/modules/devel/git/clone.lua +++ b/xmake/modules/devel/git/clone.lua @@ -62,7 +62,7 @@ end -- import("devel.git") -- -- git.clone("[email protected]:xmake-io/xmake.git") --- git.clone("[email protected]:xmake-io/xmake.git", {depth = 1, branch = "master", outputdir = "/tmp/xmake", longpaths = true}) +-- git.clone("[email protected]:xmake-io/xmake.git", {depth = 1, treeless = true, branch = "master", outputdir = "/tmp/xmake", longpaths = true}) -- -- @endcode -- @@ -87,6 +87,12 @@ function main(url, opt) table.insert(argv, type(opt.depth) == "number" and tostring(opt.depth) or opt.depth) end + -- treeless? + -- @see https://github.com/xmake-io/xmake/issues/5507 + if opt.treeless then + table.insert(argv, "--filter=tree:0") + end + -- recursive? if opt.recursive then table.insert(argv, "--recursive") |
