diff options
author | Sol Jerome <solj@ices.utexas.edu> | 2010-01-13 16:45:39 +0000 |
---|---|---|
committer | Sol Jerome <solj@ices.utexas.edu> | 2010-01-13 16:45:39 +0000 |
commit | e966b4a4972af39ffec345e5ebe362b7565fc4b5 (patch) | |
tree | 1e82a453602d7d239321e6cb24c2b194da60a8cd /tools/export.sh | |
parent | 18ec3026423c509fdffdde302676088798405082 (diff) | |
download | bcfg2-e966b4a4972af39ffec345e5ebe362b7565fc4b5.tar.gz bcfg2-e966b4a4972af39ffec345e5ebe362b7565fc4b5.tar.bz2 bcfg2-e966b4a4972af39ffec345e5ebe362b7565fc4b5.zip |
tools/export.sh: Add version bump to export script
Signed-off-by: Sol Jerome <solj@ices.utexas.edu>
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@5677 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'tools/export.sh')
-rwxr-xr-x | tools/export.sh | 32 |
1 files changed, 30 insertions, 2 deletions
diff --git a/tools/export.sh b/tools/export.sh index 48eb93112..67db7dd80 100755 --- a/tools/export.sh +++ b/tools/export.sh @@ -7,10 +7,39 @@ expath="/tmp/${name}-${version}/" tarname="/tmp/${name}-${version}.tar.gz" url=`svn info | grep URL | awk '{print $2}'` -if [ -z "$version" ] ; then +if [ -z "${version}" ] ; then echo "must supply version number" exit 1 fi + +# update the version +deblogtmp=`mktemp` +majorver=`/usr/bin/python -c "print '${version}'[:5]"` +minorver=`/usr/bin/python -c "print '${version}'[5:]"` +printf "name: " +read name +printf "email: " +read email +cat > deblogtmp << EOF +bcfg2 (${majorver}-0.0${minorver}) unstable; urgency=low + + * New upstream release + + -- ${name} <${email}> `/bin/date -R` + +EOF +sed -i "s/^\(Version:\) [:digits:]*.*$/\1 ${version}/" misc/bcfg2.spec +sed -i "s|^\(Source0:\).*$|\1 ftp://ftp.mcs.anl.gov/pub/bcfg/bcfg2-${version}.tar.gz|" misc/bcfg2.spec +sed -i "s/^\(%setup -q -n\).*/\1 bcfg2-${version}/" misc/bcfg2.spec +cat debian/changelog >> deblogtmp +mv deblogtmp debian/changelog +echo ${majorver} > redhat/VERSION +echo 0.0${minorver} > redhat/RELEASE +sed -i "s/\(version=\).*/\1\"${version}\",/" setup.py +sed -i "s/^\(VERS\).*/\1=${version}-1/" solaris/Makefile +svn ci -m "Version bump to ${version}" + +# tag the release tagstr=`echo ${version} | sed -e 's/\./_/g'` svn copy "$url" "${repo}/tags/${name}_${tagstr}" -m "tagged ${version} release" svn export . "${expath}" @@ -20,4 +49,3 @@ cd /tmp tar czf "${tarname}" "${name}-${version}" gpg --armor --output "${tarname}".gpg --detach-sig "${tarname}" scp "${tarname}"* terra.mcs.anl.gov:/mcs/ftp/pub/bcfg - |