Skip to content
This repository has been archived by the owner on Jun 19, 2023. It is now read-only.

Commit

Permalink
Adds filter hook version in for release start
Browse files Browse the repository at this point in the history
Also adds sample script.

Signed-off-by: Peter van der Does <peter@avirtualhome.com>
  • Loading branch information
petervanderdoes committed Jan 4, 2012
1 parent 22ccaed commit 104af03
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
4 changes: 4 additions & 0 deletions git-flow-release
Expand Up @@ -153,6 +153,10 @@ cmd_start() {
DEFINE_boolean fetch false "fetch from $ORIGIN before performing finish" F DEFINE_boolean fetch false "fetch from $ORIGIN before performing finish" F
parse_args "$@" parse_args "$@"
BASE=${2:-$DEVELOP_BRANCH} BASE=${2:-$DEVELOP_BRANCH}
# Run filter on the version
VERSION=`run_filter_hook release-start-version $VERSION`
# As VERSION might have changed reset BRANCH with new VERSION
BRANCH=$PREFIX$VERSION
require_version_arg require_version_arg
require_base_is_on_develop require_base_is_on_develop
require_no_existing_release_branches require_no_existing_release_branches
Expand Down
14 changes: 14 additions & 0 deletions hooks/filter-flow-release-start-version
@@ -0,0 +1,14 @@
#!/bin/sh
#
# Runs during git flow release start
#
# Positional arguments:
# $1 Version
#
VERSION=$1

# Implement your script here.

# Return the VERSION
echo ${VERSION}
exit 0

0 comments on commit 104af03

Please sign in to comment.