summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--makerpm.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/makerpm.sh b/makerpm.sh
index 6427df6..74d7c00 100644
--- a/makerpm.sh
+++ b/makerpm.sh
@@ -28,8 +28,8 @@ create_dir()
gittotar()
{
# Only archives committed changes
- git archive --format=tar.gz --prefix=${SRCTAR_DIR}/ HEAD --output ${SRCTAR}
- if [ $? -ne 0 ] ; then
+ git archive --format=tar --prefix=${SRCTAR_DIR}/ HEAD | gzip -c > ${SRCTAR}
+ if [ $? -ne 0 -o \! -s ${SRCTAR} ] ; then
fail "Unable to create git archive" $?
fi
}