Makes maketarball more resilient to errors

This commit is contained in:
Will Kahn-Greene 2011-07-05 09:36:07 -04:00
parent 132773ae08
commit 5ed4722de8

View File

@ -39,6 +39,16 @@ git archive \
--prefix=mediagoblin-$PREFIX/ \
$REVISH > mediagoblin-$PREFIX.tar
if [[ $? -ne 0 ]]
then
echo "git archive command failed. See above text for reason."
if [[ -e mediagoblin-$PREFIX.tar ]]
then
rm mediagoblin-$PREFIX.tar
fi
exit 1;
fi
echo "compressing...."
gzip mediagoblin-$PREFIX.tar