ignore set-head errors

This commit is contained in:
z4yx 2020-04-27 14:00:23 +08:00
parent 2dced2260d
commit b095caeec0
2 changed files with 2 additions and 2 deletions

View File

@ -16,7 +16,7 @@ function update_font_git() {
echo "==== SYNC $repo_dir START ====" echo "==== SYNC $repo_dir START ===="
git remote set-url origin "$UPSTREAM" git remote set-url origin "$UPSTREAM"
/usr/bin/timeout -s INT 3600 git remote -v update -p /usr/bin/timeout -s INT 3600 git remote -v update -p
git remote set-head origin --auto git remote set-head origin --auto || true
objs=$(find objects -type f | wc -l) objs=$(find objects -type f | wc -l)
[[ "$objs" -gt 8 ]] && git repack -a -b -d [[ "$objs" -gt 8 ]] && git repack -a -b -d
sz=$(git count-objects -v|grep -Po '(?<=size-pack: )\d+') sz=$(git count-objects -v|grep -Po '(?<=size-pack: )\d+')

View File

@ -14,7 +14,7 @@ function update_cocoapods_git() {
echo "==== SYNC $repo_dir START ====" echo "==== SYNC $repo_dir START ===="
git remote set-url origin "$UPSTREAM" git remote set-url origin "$UPSTREAM"
/usr/bin/timeout -s INT 3600 git remote -v update -p /usr/bin/timeout -s INT 3600 git remote -v update -p
git remote set-head origin --auto git remote set-head origin --auto || true
objs=$(find objects -type f | wc -l) objs=$(find objects -type f | wc -l)
[[ "$objs" -gt 8 ]] && git repack -a -b -d [[ "$objs" -gt 8 ]] && git repack -a -b -d
sz=$(git count-objects -v|grep -Po '(?<=size-pack: )\d+') sz=$(git count-objects -v|grep -Po '(?<=size-pack: )\d+')