From 938b7b5d83efe4746c16a37dd55c432917460ff2 Mon Sep 17 00:00:00 2001 From: Luke Ceddia Date: Fri, 19 Jan 2018 21:15:29 +1100 Subject: [PATCH] Retry Travis deployment on error --- .travis/deploy.sh | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.travis/deploy.sh b/.travis/deploy.sh index 6eced165d..6ed587faa 100755 --- a/.travis/deploy.sh +++ b/.travis/deploy.sh @@ -15,6 +15,11 @@ tar --create --auto-compress --file ${filebase}_lnx.tar.gz --exclude-from=qb64/. #7z a -xr@qb64/.travis/common-exclusion.list -xr@qb64/.travis/win-exclusion.list ${filebase}_win.7z qb64/ > /dev/null # Send to server -scp ${filebase}_* m6rosupy1q2t@qb64.org:autobuilds/${TRAVIS_BRANCH}/ - +# Sometimes the connection can be a bit flakey, so try multiple times on error +for i in `seq 1 10` +do scp ${filebase}_* m6rosupy1q2t@qb64.org:autobuilds/${TRAVIS_BRANCH}/ + if [ "$?" -eq 0 ] + then break + fi +done