aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPierre Fenoll <[email protected]>2018-08-11 15:54:29 +0200
committerPierre Fenoll <[email protected]>2018-08-11 17:56:08 +0200
commitea26bbe37f65e7793158f75c6abf126405824cbb (patch)
tree417d4c11bf81babcc84dc99cfdb73d4dcb601f39
parentf5a10287a7173524274e964a2f22f3c5a7bfe54b (diff)
downloadkerl-clone_depth.tar.gz
kerl-clone_depth.tar.bz2
kerl-clone_depth.zip
clone repos with the smallest depth for speed and spaceclone_depth
Since kerl first does a mirror clone (to act as a cache) this optimization cannot be used on these clones.
-rwxr-xr-xkerl4
1 files changed, 2 insertions, 2 deletions
diff --git a/kerl b/kerl
index a7f1e0c..9ea8870 100755
--- a/kerl
+++ b/kerl
@@ -409,7 +409,7 @@ do_git_build() {
rm -Rf "${KERL_BUILD_DIR:?}/$3"
mkdir -p "$KERL_BUILD_DIR/$3" || exit 1
cd "$KERL_BUILD_DIR/$3" || exit 1
- if ! git clone -l "$KERL_GIT_DIR/$GIT" otp_src_git >/dev/null 2>&1; then
+ if ! git clone -l --depth=1 "$KERL_GIT_DIR/$GIT" otp_src_git >/dev/null 2>&1; then
echo 'Error cloning local git repository'
exit 1
fi
@@ -1176,7 +1176,7 @@ install_docsh() {
rm -Rf "$DOCSH_DIR"
mkdir -p "$DOCSH_DIR" || exit 1
cd "$DOCSH_DIR" || exit 1
- if ! git clone -l "$KERL_GIT_DIR/$GIT" "$DOCSH_DIR" >/dev/null 2>&1; then
+ if ! git clone -l --depth=1 "$KERL_GIT_DIR/$GIT" "$DOCSH_DIR" >/dev/null 2>&1; then
echo 'Error cloning local git repository'
exit 1
fi