mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-23 16:12:01 +00:00
Merge pull request #64125 from ClickHouse/retries-in-submodules
Add retries in `git submodule update`
This commit is contained in:
commit
46f951ab7e
@ -160,10 +160,17 @@ function clone_submodules
|
|||||||
|
|
||||||
git submodule sync
|
git submodule sync
|
||||||
git submodule init
|
git submodule init
|
||||||
# --jobs does not work as fast as real parallel running
|
|
||||||
printf '%s\0' "${SUBMODULES_TO_UPDATE[@]}" | \
|
# Network is unreliable
|
||||||
xargs --max-procs=100 --null --no-run-if-empty --max-args=1 \
|
for _ in {1..10}
|
||||||
git submodule update --depth 1 --single-branch
|
do
|
||||||
|
# --jobs does not work as fast as real parallel running
|
||||||
|
printf '%s\0' "${SUBMODULES_TO_UPDATE[@]}" | \
|
||||||
|
xargs --max-procs=100 --null --no-run-if-empty --max-args=1 \
|
||||||
|
git submodule update --depth 1 --single-branch && break
|
||||||
|
sleep 1
|
||||||
|
done
|
||||||
|
|
||||||
git submodule foreach git reset --hard
|
git submodule foreach git reset --hard
|
||||||
git submodule foreach git checkout @ -f
|
git submodule foreach git checkout @ -f
|
||||||
git submodule foreach git clean -xfd
|
git submodule foreach git clean -xfd
|
||||||
|
Loading…
Reference in New Issue
Block a user