Fix git-archive invocation for RHEL 6
Apparently, on RHEL 6, the valid archive type is tar, not tar.gz. It causes git-archive and thus makerpm.sh to abort with: fatal: Unknown archive format 'tar.gz' To fix, use a regular pipeline. Change-Id: I9174ad1d1c0e087f46ecd31eade61eeea75cb9cb Signed-off-by: Pete Zaitcev <zaitcev@kotori.zaitcev.us> Reviewed-on: http://review.gluster.org/5271 Reviewed-by: Luis Pabon <lpabon@redhat.com> Tested-by: Luis Pabon <lpabon@redhat.com>
This commit is contained in:
parent
5cef798f8d
commit
ceb18f16cc
@ -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
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user