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

Commit

Permalink
Merge branch 'release/1.10.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
petervanderdoes committed Aug 11, 2016
2 parents 43548ed + 6f56843 commit 7d931f7
Show file tree
Hide file tree
Showing 18 changed files with 709 additions and 572 deletions.
18 changes: 18 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# This is the top-most .editorconfig file; do not search in parent directories.
root = true

[*]
end_of_line = LF
insert_final_newline = true
trim_trailing_whitespace = true

[Changes.mdown]
indent_style = space
indent_size = 2

[*.mdown]
trim_trailing_whitespace = false

[{Makefile, makefile, GNUmakefile}]
indent_style = tab
indent_size = 4
4 changes: 4 additions & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ Alexander Groß
Alexander Norström
Alexander Zeitler
Brian St. Pierre
Cararus Eugeniu
Chad Walker
Craig Fowler
Emre Berge Ergenekon
Expand All @@ -46,7 +47,10 @@ John Sivak
Jon Bernard
Joseph A. Levin
Joshua P. Tilles
Juan Rial
Justin Penney
Konstantin Tjuterev
Kridsada Thanabulpong
Leonardo Giordani
Mark Borcherding
Mark Derricutt
Expand Down
23 changes: 22 additions & 1 deletion Changes.mdown
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,30 @@
[algernon]: https://github.com/algernon
[jebmeier]: https://github.com/jebmeier
[aleno]: https://github.com/aleno

[sirn]: https://github.com/sirn
[jpenney78]: https://github.com/jpenney78

# Changelog

#### 1.10.0
[Peter van der Does][petervanderdoes]
* Update github links.
* Add explanation of AVH.
* Add ability when finishing a release to push or not push the branches and/or tag involved.
* The finishing of a release branch based on a branch other than develop fails with errors.
* Add --push flag for feature finish. This gives the ability to push the base branch after the finish.
* When finishing a release have the ability to fast-forward the master branch, if possible.
This is controlled by the flag --ff-master.
* Add new flag -T, --tagname to override the tag name when finishing a release or hotfix.
* Allow multiple hotfix branches by setting the config allowmultihotfix to true.
The command to set it is

[Kridsada Thanabulpong][sirn]
* Fix infinite loop during Darwin link resolving.

[Justin Penney][jpenney78]
* Add detection for BusyBox getopt.

#### 1.9.1
[Peter van der Does][petervanderdoes]
* Bugfix: git-flow directories are not set correctly
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
#
# Authors:
# Copyright 2012-2015 Peter van der Does. All rights reserved.
# Copyright 2012-2016 Peter van der Does. All rights reserved.
#
# Original Author:
# Copyright 2010 Vincent Driessen. All rights reserved.
#
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
Expand Down
15 changes: 9 additions & 6 deletions README.mdown
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,15 @@ Or have a look at one of these screen casts:

* [How to use a scalable Git branching model called git-flow](http://buildamodule.com/video/change-management-and-version-control-deploying-releases-features-and-fixes-with-git-how-to-use-a-scalable-git-branching-model-called-gitflow) (by Build a Module)
* [A short introduction to git-flow](http://vimeo.com/16018419) (by Mark Derricutt)
* [On the path with git-flow](http://codesherpas.com/screencasts/on_the_path_gitflow.mov) (by Dave Bock)
* [On the path with git-flow](https://vimeo.com/codesherpas/on-the-path-gitflow) (by Dave Bock)

A quick cheatsheet was made by Daniel Kummer:

[http://danielkummer.github.io/git-flow-cheatsheet/](http://danielkummer.github.io/git-flow-cheatsheet/)

## Installing git-flow

See the Wiki for up-to-date [Installation Instructions](https://github.com/petervanderdoes/gitflow/wiki/Installation).
See the Wiki for up-to-date [Installation Instructions](https://github.com/petervanderdoes/gitflow-avh/wiki/Installation).


## Integration with your shell
Expand All @@ -37,17 +40,18 @@ for the commands not found in the original git-flow.

## FAQ

* See the [FAQ](http://github.com/petervanderdoes/gitflow/wiki/FAQ) section
* See the [FAQ](http://github.com/petervanderdoes/gitflow-avh/wiki/FAQ) section
of the project Wiki.
* Version Numbering Scheme.
Starting with version 1.0, the project uses the following scheme:
\<MAJOR\>.\<MINOR\>.\<REVISION\>\
* AVH is the acronym of "A VirtualHome"

## Please help out

This project is under constant development. Feedback and suggestions are very
welcome and I encourage you to use the [Issues
list](http://github.com/petervanderdoes/gitflow/issues) on Github to provide that
list](http://github.com/petervanderdoes/gitflow-avh/issues) on Github to provide that
feedback.

Feel free to fork this repository and to commit your additions. For a list of
Expand Down Expand Up @@ -114,6 +118,7 @@ those questions to accept the (sane) default suggestions.

The ``-d`` flag will accept all defaults.

![Screencast git flow init](http://i.imgur.com/lFQbY5V.gif)

### Creating feature/release/hotfix/support branches

Expand Down Expand Up @@ -198,5 +203,3 @@ in another way, however, consider donating through PayPal:
[1]: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=S85FXJ9EBHAF2&lc=US&item_name=gitflow&item_number=gitflow&no_note=0&cn=Add%20special%20instructions%20to%20the%20seller&no_shipping=1&rm=1&return=https%3a%2f%2fgithub%2ecom%2fpetervanderdoes%2fgitflow&cancel_return=https%3a%2f%2fgithub%2ecom%2fpetervanderdoes%2fgitflow&currency_code=USD&bn=PP%2dDonationsBF%3abtn_donate_SM%2egif%3aNonHosted

[2]: https://www.paypalobjects.com/en_US/i/btn/btn_donate_SM.gif

[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/petervanderdoes/gitflow/trend.png)](https://bitdeli.com/free "Bitdeli Badge")
4 changes: 2 additions & 2 deletions contrib/gitflow-installer.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

# git-flow make-less installer for *nix systems, by Rick Osborne
# Based on the git-flow core Makefile:
# http://github.com/petervanderdoes/gitflow/blob/master/Makefile
# http://github.com/petervanderdoes/gitflow-avh/blob/master/Makefile

# Licensed under the same restrictions as git-flow:
# http://github.com/petervanderdoes/gitflow/blob/develop/LICENSE
# http://github.com/petervanderdoes/gitflow-avh/blob/develop/LICENSE

# Updated for the fork at petervanderdoes

Expand Down
4 changes: 2 additions & 2 deletions git-flow
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
# http://github.com/petervanderdoes/gitflow
#
# Authors:
# Copyright 2012-2015 Peter van der Does. All rights reserved.
# Copyright 2012-2016 Peter van der Does. All rights reserved.
#
# Original Author:
# Copyright 2010 Vincent Driessen. All rights reserved.
Expand Down Expand Up @@ -55,7 +55,7 @@ FreeBSD|OpenBSD|NetBSD)
Darwin)
PRG="$0"
while [ -h "$PRG" ]; do
link=$(readlink "$0")
link=$(readlink "$PRG")
if expr "$link" : '/.*' > /dev/null; then
PRG="$link"
else
Expand Down
2 changes: 1 addition & 1 deletion git-flow-bugfix
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# http://github.com/petervanderdoes/gitflow
#
# Authors:
# Copyright 2012-2015 Peter van der Does. All rights reserved.
# Copyright 2012-2016 Peter van der Does. All rights reserved.
#
# Original Author:
# Copyright 2010 Vincent Driessen. All rights reserved.
Expand Down
19 changes: 16 additions & 3 deletions git-flow-config
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# http://github.com/petervanderdoes/gitflow
#
# Authors:
# Copyright 2012-2015 Peter van der Does. All rights reserved.
# Copyright 2012-2016 Peter van der Does. All rights reserved.
#
#
# Redistribution and use in source and binary forms, with or without
Expand Down Expand Up @@ -137,8 +137,6 @@ git flow config set <option> <value>
Set the git-flow configuration option to the given value
--
h,help! Show this help

Use config file location
local! Use repository config file
global! Use global config file
system! Use system config file
Expand Down Expand Up @@ -190,6 +188,10 @@ file= Use given config file
cfg_option="gitflow.prefix.versiontag"
txt="Version tag prefix"
;;
allowmultihotfix)
cfg_option="gitflow.multi-hotfix"
txt="Allow multiple hotfix branches"
;;
*)
die_help "Invalid option given."
;;
Expand Down Expand Up @@ -223,6 +225,17 @@ file= Use given config file
fi
fi

if [ $OPTION = "allowmultihotfix" ]; then
check_boolean "${value}"
case $? in
${FLAGS_ERROR})
die "Invalid value for option 'allowmultihotfix'. Valid values are 'true' or 'false'"
;;
*)
;;
esac
fi

git_do config $gitflow_config_option $cfg_option "$value"

case $? in
Expand Down
10 changes: 9 additions & 1 deletion git-flow-feature
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#@IgnoreInspection BashAddShebang
#
# git-flow -- A collection of Git extensions to provide high-level
# repository operations for Vincent Driessen's branching model.
Expand All @@ -9,7 +10,7 @@
# http://github.com/petervanderdoes/gitflow
#
# Authors:
# Copyright 2012-2015 Peter van der Does. All rights reserved.
# Copyright 2012-2016 Peter van der Does. All rights reserved.
#
# Original Author:
# Copyright 2010 Vincent Driessen. All rights reserved.
Expand Down Expand Up @@ -243,6 +244,7 @@ showcommands! Show git commands while executing them
F,[no]fetch Fetch from origin before performing finish
r,[no]rebase Rebase before merging
p,[no]preserve-merges Preserve merges while rebasing
[no]push Push to origin after performing finish
k,[no]keep Keep branch after performing finish
keepremote! Keep the remote branch
keeplocal! Keep the local branch
Expand All @@ -256,6 +258,7 @@ no-ff! Never fast-forward during the merge
DEFINE_boolean 'fetch' false "fetch from $ORIGIN before performing finish" F
DEFINE_boolean 'rebase' false "rebase before merging" r
DEFINE_boolean 'preserve-merges' false 'try to recreate merges while rebasing' p
DEFINE_boolean 'push' false "push to $ORIGIN after performing finish" p
DEFINE_boolean 'keep' false "keep branch after performing finish" k
DEFINE_boolean 'keepremote' false "keep the remote branch"
DEFINE_boolean 'keeplocal' false "keep the local branch"
Expand All @@ -268,6 +271,7 @@ no-ff! Never fast-forward during the merge
gitflow_override_flag_boolean "feature.finish.fetch" "fetch"
gitflow_override_flag_boolean "feature.finish.rebase" "rebase"
gitflow_override_flag_boolean "feature.finish.preserve-merges" "preserve_merges"
gitflow_override_flag_boolean "feature.finish.push" "push"
gitflow_override_flag_boolean "feature.finish.keep" "keep"
gitflow_override_flag_boolean "feature.finish.keepremote" "keepremote"
gitflow_override_flag_boolean "feature.finish.keeplocal" "keeplocal"
Expand Down Expand Up @@ -464,6 +468,10 @@ helper_finish_cleanup() {
fi
fi

if flag push; then
git_do push "$ORIGIN" "$BASE_BRANCH" || die "Could not push branch '$BASE_BRANCH' to remote '$ORIGIN'."
fi

echo
echo "Summary of actions:"
echo "- The feature branch '$BRANCH' was merged into '$BASE_BRANCH'"
Expand Down
35 changes: 22 additions & 13 deletions git-flow-hotfix
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# http://github.com/petervanderdoes/gitflow
#
# Authors:
# Copyright 2012-2015 Peter van der Does. All rights reserved.
# Copyright 2012-2016 Peter van der Does. All rights reserved.
#
# Original Author:
# Copyright 2010 Vincent Driessen. All rights reserved.
Expand Down Expand Up @@ -375,6 +375,7 @@ D,[no]force_delete Force delete hotfix branch after finish
n,[no]notag Don't tag this hotfix
b,[no]nobackmerge Don't back-merge master, or tag if applicable, in develop
S,[no]squash Squash hotfix during merge
T,tagname! Use given tag name
"
local opts commit keepmsg remotebranchdeleted localbranchdeleted

Expand All @@ -393,6 +394,7 @@ S,[no]squash Squash hotfix during merge
DEFINE_boolean 'nobackmerge' false "don't back-merge $MASTER_BRANCH, or tag if applicable, in $DEVELOP_BRANCH " b
DEFINE_boolean 'squash' false "squash release during merge" S
DEFINE_boolean 'squash-info' false "add branch info during squash"
DEFINE_string 'tagname' "" "use the given tag name" T

# Override defaults with values from config
gitflow_override_flag_boolean "hotfix.finish.fetch" "fetch"
Expand All @@ -404,8 +406,8 @@ S,[no]squash Squash hotfix during merge
gitflow_override_flag_boolean "hotfix.finish.force-delete" "force_delete"
gitflow_override_flag_boolean "hotfix.finish.notag" "notag"
gitflow_override_flag_boolean "hotfix.finish.nobackmerge" "nobackmerge"
gitflow_override_flag_boolean "release.finish.squash" "squash"
gitflow_override_flag_boolean "release.finish.squash-info" "squash_info"
gitflow_override_flag_boolean "hotfix.finish.squash" "squash"
gitflow_override_flag_boolean "hotfix.finish.squash-info" "squash_info"
gitflow_override_flag_string "hotfix.finish.signingkey" "signingkey"
gitflow_override_flag_string "hotfix.finish.message" "message"
gitflow_override_flag_string "hotfix.finish.messagefile" "messagefile"
Expand All @@ -418,6 +420,13 @@ S,[no]squash Squash hotfix during merge
gitflow_use_current_branch_version
fi

# Use branch name if no tag name is given
if [ "$FLAGS_tagname" != "" ]; then
TAGNAME=$FLAGS_tagname
else
TAGNAME=$VERSION
fi

remotebranchdeleted=$FLAGS_FALSE
localbranchdeleted=$FLAGS_FALSE

Expand Down Expand Up @@ -491,13 +500,13 @@ S,[no]squash Squash hotfix during merge
if noflag notag; then
# We ask for a tag, be sure it does not exists or
# points to the latest hotfix commit
if git_tag_exists "$VERSION_PREFIX$VERSION"; then
git_compare_refs "$BRANCH" "$VERSION_PREFIX$VERSION"^2 2>/dev/null
if git_tag_exists "$VERSION_PREFIX$TAGNAME"; then
git_compare_refs "$BRANCH" "$VERSION_PREFIX$TAGNAME"^2 2>/dev/null
[ $? -eq 0 ] || die "Tag already exists and does not point to hotfix branch '$BRANCH'"
fi
fi

run_pre_hook "$VERSION_PREFIX$VERSION" "$ORIGIN" "$BRANCH"
run_pre_hook "$VERSION_PREFIX$TAGNAME" "$ORIGIN" "$BRANCH"

# Try to merge into BASE.
# In case a previous attempt to finish this release branch has failed,
Expand All @@ -517,7 +526,7 @@ S,[no]squash Squash hotfix during merge
# Try to tag the release.
# In case a previous attempt to finish this release branch has failed,
# but the tag was set successful, we skip it now
if ! git_tag_exists "$VERSION_PREFIX$VERSION"; then
if ! git_tag_exists "$VERSION_PREFIX$TAGNAME"; then
if [ "$FLAGS_message" != "" ] && [ "$FLAGS_messagefile" != "" ]; then
die "Use either -m,--message or -f,--messagefile. Can not use both options at the same time"
fi
Expand All @@ -526,11 +535,11 @@ S,[no]squash Squash hotfix during merge
[ "$FLAGS_signingkey" != "" ] && opts="$opts -u '$FLAGS_signingkey'"
if [ "$FLAGS_message" != "" ]; then
# Run filter on the tag message
FLAGS_message=$(run_filter_hook hotfix-finish-tag-message "${FLAGS_message}" "$VERSION_PREFIX$VERSION")
FLAGS_message=$(run_filter_hook hotfix-finish-tag-message "${FLAGS_message}" "$VERSION_PREFIX$TAGNAME")
opts="$opts -m '$FLAGS_message'"
fi
[ "$FLAGS_messagefile" != "" ] && opts="$opts -F '$FLAGS_messagefile'"
eval git_do tag $opts "$VERSION_PREFIX$VERSION" || die "Tagging failed. Please run finish again to retry."
eval git_do tag $opts "$VERSION_PREFIX$TAGNAME" || die "Tagging failed. Please run finish again to retry."
fi
fi

Expand All @@ -553,7 +562,7 @@ S,[no]squash Squash hotfix during merge
# Accounting for 'git describe', if a release is tagged
# we use the tag commit instead of the branch.
if noflag notag; then
commit="$VERSION_PREFIX$VERSION"
commit="$VERSION_PREFIX$TAGNAME"
else
commit="$BASE_BRANCH"
fi
Expand All @@ -566,7 +575,7 @@ S,[no]squash Squash hotfix during merge
fi
fi

run_post_hook "$VERSION_PREFIX$VERSION" "$ORIGIN" "$BRANCH"
run_post_hook "$VERSION_PREFIX$TAGNAME" "$ORIGIN" "$BRANCH"

# Delete branch
if noflag keep; then
Expand Down Expand Up @@ -614,11 +623,11 @@ S,[no]squash Squash hotfix during merge
fi
echo "- Hotfix branch '$BRANCH' has been merged into '$BASE_BRANCH'"
if noflag notag; then
echo "- The hotfix was tagged '$VERSION_PREFIX$VERSION'"
echo "- The hotfix was tagged '$VERSION_PREFIX$TAGNAME'"
fi
if [ "$BASE_BRANCH" = "$MASTER_BRANCH" ]; then
[ "$commit" = "$BASE_BRANCH" ] && echo "- Master branch '$BASE_BRANCH' has been back-merged into '$DEVELOP_BRANCH'"
[ "$commit" = "$VERSION_PREFIX$VERSION" ] && echo "- Hotfix tag '$VERSION_PREFIX$VERSION' has been back-merged into '$DEVELOP_BRANCH'"
[ "$commit" = "$VERSION_PREFIX$TAGNAME" ] && echo "- Hotfix tag '$VERSION_PREFIX$TAGNAME' has been back-merged into '$DEVELOP_BRANCH'"
[ "$commit" = "$BRANCH" ] && echo "- Hotfix branch '$BRANCH' has been merged into '$DEVELOP_BRANCH'"
fi
if noflag keep; then
Expand Down
Loading

0 comments on commit 7d931f7

Please sign in to comment.