From 392e8d24a9524d20cfd151cfbfd2c68d4f1c1182 Mon Sep 17 00:00:00 2001 From: janbar Date: Fri, 24 May 2024 17:56:29 +0800 Subject: [PATCH] reduce git clone download data size Only gi clone the latest code, do not git clone the complete warehouse --- lib/util.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/util.lua b/lib/util.lua index 2f090d3..0a414c3 100644 --- a/lib/util.lua +++ b/lib/util.lua @@ -214,7 +214,7 @@ function linuxCompile(ctx) local version = sdkInfo.version local pyenv_url = "https://github.com/pyenv/pyenv.git" local dest_pyenv_path = ctx.rootPath .. "/pyenv" - local status = os.execute("git clone " .. pyenv_url .. " " .. dest_pyenv_path) + local status = os.execute("git clone --depth 1 " .. pyenv_url .. " " .. dest_pyenv_path) if status ~= 0 then error("git clone failed") end