#!/bin/sh
-# Copyright (c) 2011 IndexData ApS. http://indexdata.com
+# Copyright (c) 2011-2015 IndexData ApS. http://indexdata.com
# Author: Wolfram Schneider
#
# id-release - a helper script to build a release & packaging for debian + redhat
#
# see http://twiki.indexdata.dk/cgi-bin/twiki/view/ID/IDSoftwareRelease
+# https://twiki.indexdata.com/twiki/bin/view/ID/AdamsReleaseProcedure
# die early
set -e
* ) usage ;;
esac
+echo "See also https://twiki.indexdata.com/twiki/bin/view/ID/AdamsReleaseProcedure"
+echo ""
+
echo "Did you updated the news log file?"
for file in Changes News NEWS
do
perl -i.bak -npe "s,^Version: \d+.*,Version: $version," $spec
-
######################################################################
-echo ""
echo "# Please commit the version updates now"
echo "git commit -a -m'new release v$version'"
echo ""
-echo "# Please run now"
-echo "git push"
+echo "# Please tag now (we will push later to origin)"
echo "git tag v$version"
-echo "git push origin tag v$version"
if $java; then
echo "mvn versions:set -DnewVersion=$version-SNAPSHOT"
######################################################################
echo ""
-echo "# On RedHat or centos, please run the commands"
-echo "sudo date # ask for password early"
-echo "git pull"
+echo "# On mochi, please run the commands"
echo "\$HOME/proj/git-tools/id-deb-build/mkdist.sh"
-echo "sudo cp $package-$version.tar.gz /usr/src/redhat/SOURCES/"
-echo "sudo rpmbuild -ba $spec"
-echo "# if successfully, scp the package to ftp.indexdata.dk (kebab)"
-echo "\$HOME/proj/git-tools/id-rpm-build/upload-rpms.sh $spec"
-echo ""
-echo "# on kebab run: sudo su"
-echo "# cd $HOME/proj/git-tools/update-archive && ./update-yum-archive.sh"
-
-
-######################################################################
-echo ""
-echo "# On debian or ubuntu, please run the commands"
-echo "sudo rm -rf deb-src"
-echo "git pull"
-echo "\$HOME/proj/git-tools/id-deb-build/mkdist.sh"
-echo "\$HOME/proj/git-tools/id-deb-build/id-mk-deb-src.sh"
-echo "sudo \$HOME/proj/git-tools/id-deb-build/id-pbuild.sh"
-echo "# if successfully, scp the package to ftp.indexdata.dk (kebab)"
+echo "\$HOME/proj/git-tools/id-deb-build/id-pbuild.sh"
echo "\$HOME/proj/git-tools/id-deb-build/id-pbuild.sh --upload"
echo ""
-echo "# on kebab run: sudo su"
-echo "# cd $HOME/proj/git-tools/update-archive && ./update-archive.sh"
-echo ""
+echo "# if successfully, don't forget to push to origin"
+echo "git push origin master"
+echo "git push origin tag v$version"