quieten a little
This commit is contained in:
parent
dc0ed1b79d
commit
7eb6b5769e
@ -38,8 +38,12 @@ DEBUG=
|
|||||||
if [ ${smegit_DEBUG} == "true" ] ; then DEBUG=true ; fi
|
if [ ${smegit_DEBUG} == "true" ] ; then DEBUG=true ; fi
|
||||||
if [ $DEBUG ] ; then echo "found ini file: $inifilename" ; fi
|
if [ $DEBUG ] ; then echo "found ini file: $inifilename" ; fi
|
||||||
|
|
||||||
curlsilent="-s"
|
SILENT="-s"
|
||||||
if [ $DEBUG ] ; then curlsilent= ; fi
|
QUIET="-q"
|
||||||
|
if [ $DEBUG ] ; then
|
||||||
|
SILENT=
|
||||||
|
QUIET=
|
||||||
|
fi
|
||||||
|
|
||||||
GITEAHOST=${remote_GITEAHOST}
|
GITEAHOST=${remote_GITEAHOST}
|
||||||
ACCESSTOKEN=${remote_GITEAACCESSTOKEN}
|
ACCESSTOKEN=${remote_GITEAACCESSTOKEN}
|
||||||
@ -76,7 +80,7 @@ if [ $DEBUG ] ; then echo $GITFiles ; fi
|
|||||||
if [ ! -e $GITFiles/common ]; then
|
if [ ! -e $GITFiles/common ]; then
|
||||||
#Get it
|
#Get it
|
||||||
cd $GITFiles
|
cd $GITFiles
|
||||||
git clone "${smegit_COMMONREPO}"
|
git clone $QUIET "${smegit_COMMONREPO}"
|
||||||
if [ ! -e $GITFiles/common ]; then
|
if [ ! -e $GITFiles/common ]; then
|
||||||
echo "ERROR*******No Common Repo found - package $REPO_NAME"
|
echo "ERROR*******No Common Repo found - package $REPO_NAME"
|
||||||
exit 1
|
exit 1
|
||||||
@ -84,14 +88,14 @@ if [ ! -e $GITFiles/common ]; then
|
|||||||
else
|
else
|
||||||
# Just refresh it
|
# Just refresh it
|
||||||
cd $GITFiles/common
|
cd $GITFiles/common
|
||||||
git pull
|
git $QUIET pull
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Now make sure that the make-archive is executible
|
# Now make sure that the make-archive is executible
|
||||||
chmod +x $GITFiles/common/make-archive.sh
|
chmod +x $GITFiles/common/make-archive.sh
|
||||||
|
|
||||||
# See if repo exits in git
|
# See if repo exits in git
|
||||||
RESPONSE=$(curl $curlsilent -o /dev/null -w "%{http_code}" "$GITEAHOST/api/v1/repos/$ORG_NAME/$REPO_NAME")
|
RESPONSE=$(curl $SILENT -o /dev/null -w "%{http_code}" "$GITEAHOST/api/v1/repos/$ORG_NAME/$REPO_NAME")
|
||||||
if [ "$RESPONSE" == "200" ]; then
|
if [ "$RESPONSE" == "200" ]; then
|
||||||
if [ $DEBUG ] ; then echo "Repository for $ORG_NAME/$REPO_NAME exists!" ; fi
|
if [ $DEBUG ] ; then echo "Repository for $ORG_NAME/$REPO_NAME exists!" ; fi
|
||||||
else
|
else
|
||||||
@ -106,7 +110,7 @@ else
|
|||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
# And check it is now there
|
# And check it is now there
|
||||||
RESPONSE=$(curl $curlsilent -o /dev/null -w "%{http_code}" "$GITEAHOST/api/v1/repos/$ORG_NAME/$REPO_NAME")
|
RESPONSE=$(curl $SILENT -o /dev/null -w "%{http_code}" "$GITEAHOST/api/v1/repos/$ORG_NAME/$REPO_NAME")
|
||||||
if [ "$RESPONSE" == "200" ]; then
|
if [ "$RESPONSE" == "200" ]; then
|
||||||
if [ $DEBUG ] ; then echo "Repository for $ORG_NAME/$REPO_NAME created sucessfully!" ; fi
|
if [ $DEBUG ] ; then echo "Repository for $ORG_NAME/$REPO_NAME created sucessfully!" ; fi
|
||||||
else
|
else
|
||||||
@ -125,7 +129,7 @@ if [[ -d $REPO_NAME ]] ; then
|
|||||||
rm -rf "$REPO_NAME"
|
rm -rf "$REPO_NAME"
|
||||||
fi
|
fi
|
||||||
cd $GITFiles
|
cd $GITFiles
|
||||||
git clone "$REPOURL"
|
git $QUIET clone "$REPOURL"
|
||||||
|
|
||||||
|
|
||||||
cd $GITFiles
|
cd $GITFiles
|
||||||
@ -144,12 +148,3 @@ else
|
|||||||
echo "$(date +'%FT%H%M') Mockbuild failed for $ORG_NAME/$REPO_NAME " >> $GITFiles/mockbuilds.log
|
echo "$(date +'%FT%H%M') Mockbuild failed for $ORG_NAME/$REPO_NAME " >> $GITFiles/mockbuilds.log
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user