From 32268cd2a96df93c04a119a699115aecf22fb905 Mon Sep 17 00:00:00 2001 From: Trevor Batley Date: Mon, 5 Jun 2023 10:58:40 +1000 Subject: [PATCH] error message re: unable to delete --- rename-e-smith-pkg.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/rename-e-smith-pkg.sh b/rename-e-smith-pkg.sh index 34154c6..f7c21a4 100755 --- a/rename-e-smith-pkg.sh +++ b/rename-e-smith-pkg.sh @@ -311,7 +311,11 @@ if [ $TRANSFER ] ; then "$GITEAHOST/api/v1/repos/$SOURCEORG/$TARGETPKG" \ -H 'accept: application/json' \ -H "Authorization: token $GITEAACCESSTOKEN" ) - EXISTS= + if [[ $RESPONSE != "204" ]] ; then + echo "Unable to delete $SOURCEORG/$TARGETPKG ($RESPONSE)" + else + EXISTS= + fi fi else if [ $DEBUG ] ; then echo "Repository for $SOURCEORG/$TARGETPKG does not exist on $GITEAHOST" ; fi