Skip to content

Commit

Permalink
Allow multiple hotfix branches.
Browse files Browse the repository at this point in the history
By setting the config gitflow.multi-hotfix to true, you can have multiple hotfix branches. Example: git config --set gitflow.multi-hotfix true

Closes nvie#167
  • Loading branch information
petervanderdoes committed Dec 24, 2014
1 parent aa8ca9e commit 7cab2a2
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
5 changes: 4 additions & 1 deletion Changes.mdown
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,14 @@

# Changelog

#### 1.9.0-dev.17
#### 1.9.0-dev.18
[Peter van der Does][petervanderdoes]
* Repositories with spaces in path cause the pre * post hook to fail
* Error using git flow log.
* Using defaults with init fails with existing repository.
* Allow multiple hotfix branches.
By setting the config gitflow.multi-hotfix to true, you can have multiple
hotfix branches. Example: git config --set gitflow.multi-hotfix true

[Gergely Nagy][algernon]
* Remove bash code.
Expand Down
6 changes: 4 additions & 2 deletions git-flow-hotfix
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,9 @@ F,[no]fetch Fetch from origin before performing local operation
BRANCH=$PREFIX$VERSION

gitflow_require_version_arg
require_no_existing_hotfix_branches
if ! $(git config --bool --get gitflow.multi-hotfix 2>&1); then
require_no_existing_hotfix_branches
fi

# Sanity checks
require_branch_absent "$BRANCH"
Expand Down Expand Up @@ -313,7 +315,7 @@ p,[no]preserve-merges Preserve merges
require_clean_working_tree
require_branch "$BRANCH"

git_local_branch_exists "$BASE_BRANCH" || die "The base '$BASE_BRANCH' doesn't exists locally or is not a branch. Can't rebase the hotfixe branch '$BRANCH'."
git_local_branch_exists "$BASE_BRANCH" || die "The base '$BASE_BRANCH' doesn't exists locally or is not a branch. Can't rebase the hotfixe branch '$BRANCH'."

git_do checkout -q "$BRANCH" || die "Could not check out branch '$BRANCH'."
if flag interactive; then
Expand Down
2 changes: 1 addition & 1 deletion git-flow-version
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#

GITFLOW_VERSION=1.9.0-dev.17
GITFLOW_VERSION=1.9.0-dev.18

initialize() {
# A function can not be empty. Comments count as empty.
Expand Down

0 comments on commit 7cab2a2

Please sign in to comment.