From ddd77efc5f80b7a25fdc67a83a6d6781f215ac19 Mon Sep 17 00:00:00 2001 From: David Teigland Date: Tue, 2 Jun 2009 16:12:26 -0500 Subject: cpgx: build stuff Signed-off-by: David Teigland --- cpgx/make-tarball | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100755 cpgx/make-tarball (limited to 'cpgx/make-tarball') diff --git a/cpgx/make-tarball b/cpgx/make-tarball new file mode 100755 index 0000000..f9fc44b --- /dev/null +++ b/cpgx/make-tarball @@ -0,0 +1,33 @@ +#!/bin/bash + +# to release +# edit VERSION with new number and without -git +# edit cpgx.spec with new version numbers +# commit changes to VERSION and cpgx.spec +# make tarball (uses commited VERSION and cpgx.spec) +# edit VERSION adding -git +# commit VERSION change +# push + +WC=`git diff | wc -l` + +if [ "$WC" != "0" ] +then + echo "error uncommited changes" + exit 2 +fi + +VER=`cat VERSION` + +VER2=`awk '/^Version:/ { print $2 }' < cpgx.spec` + +if [ "$VER" != "$VER2" ] +then + echo "error VERSION = $VER, cpgx.spec = $VER2" + exit 2 +fi + +echo "version $VER" + +git archive --format=tar --prefix=cpgx-$VER/ HEAD^{tree} | gzip > cpgx-$VER.tar.gz + -- cgit