From b095caeec0a0e6a542125aed3cd785a41be33857 Mon Sep 17 00:00:00 2001 From: z4yx Date: Mon, 27 Apr 2020 14:00:23 +0800 Subject: [PATCH] ignore set-head errors --- adobe-fonts.sh | 2 +- cocoapods.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/adobe-fonts.sh b/adobe-fonts.sh index 887dbf8..803c7e7 100755 --- a/adobe-fonts.sh +++ b/adobe-fonts.sh @@ -16,7 +16,7 @@ function update_font_git() { echo "==== SYNC $repo_dir START ====" git remote set-url origin "$UPSTREAM" /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" -gt 8 ]] && git repack -a -b -d sz=$(git count-objects -v|grep -Po '(?<=size-pack: )\d+') diff --git a/cocoapods.sh b/cocoapods.sh index 077cc75..adf5de5 100755 --- a/cocoapods.sh +++ b/cocoapods.sh @@ -14,7 +14,7 @@ function update_cocoapods_git() { echo "==== SYNC $repo_dir START ====" git remote set-url origin "$UPSTREAM" /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" -gt 8 ]] && git repack -a -b -d sz=$(git count-objects -v|grep -Po '(?<=size-pack: )\d+')