2010-01-26 10:55:03 +00:00
|
|
|
#!/bin/sh
|
|
|
|
usage() {
|
|
|
|
echo "usage: bump-version <version-id>"
|
|
|
|
}
|
|
|
|
|
|
|
|
if [ $# -ne 1 ]; then
|
|
|
|
usage
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
2010-01-27 23:13:26 +00:00
|
|
|
if ! sed 's/^GITFLOW_VERSION=.*$/GITFLOW_VERSION='$1'/g' git-flow-version > .git-flow-version.new; then
|
|
|
|
echo "Could not replace GITFLOW_VERSION variable." >&2
|
|
|
|
exit 2
|
|
|
|
fi
|
|
|
|
|
|
|
|
mv .git-flow-version.new git-flow-version
|
2010-01-26 14:58:08 +00:00
|
|
|
git add git-flow-version
|
|
|
|
git commit -m "Bumped version number to $1" git-flow-version
|