From 63728cc4737eeec19071505e2b5ea23805dc43af Mon Sep 17 00:00:00 2001 From: Daniel Berteaud Date: Mon, 12 Mar 2012 17:31:18 +0100 Subject: [PATCH] prefix archive to packagename-version --- buildsrpm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildsrpm b/buildsrpm index 4ca07ab..2ba9173 100755 --- a/buildsrpm +++ b/buildsrpm @@ -6,7 +6,7 @@ VERSION=$(rpm -q --qf "%{version}" --specfile $PACKAGE.spec) if [ \! -e ~/rpmbuild/SOURCES/$PACKAGE-$VERSION.tar.gz ]; then BRANCH=$(git branch | grep '*' | cut -d' ' -f2) git tag $VERSION - git archive --format=tar.gz -o ~/rpmbuild/SOURCES/$PACKAGE-$VERSION.tar.gz $BRANCH + git archive --format=tar.gz --prefix=$PACKAGE-$VERSION/ -o ~/rpmbuild/SOURCES/$PACKAGE-$VERSION.tar.gz $BRANCH fi rpmbuild -bs $PACKAGE.spec rm -f ~/rpmbuild/SOURCES/$PACKAGE-$VERSION.tar.gz