Commit 1b69a9f1 authored by Adrien Oliva's avatar Adrien Oliva

feat(script): Release script

Allow simple release commit, given a tag name and a tag message.

This script will update ChangeLog.md, NEWS.md using preparerelease
script, update AUTHORS file using git shortlog command and finally
commit and tag those files in a consistent way.
parent 03db9240
#!/bin/bash
usage()
{
echo "$0 tagname tagmessage"
echo ""
}
TAG=
TAGMESSAGE=
if [ $# -ne 2 ]; then
usage
exit 127
fi
TAG=$1
shift
TAGMESSAGE=$1
shift
preparerelease
git shortlog -sne > AUTHOR
git add AUTHOR ChangeLog.md NEWS.md
git commit -F - <<HERE
build(release): Prepare release $TAG
HERE
git tag -s "$TAG" -m "$TAGMESSAGE"
preparerelease
git shortlog -sne > AUTHOR
git add AUTHOR ChangeLog.md NEWS.md
git commit --amend
git tag -d "$TAG"
git tag -s "$TAG" -m "$TAGMESSAGE"
git push origin master --tags
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment