Added 'feature checkout' subcommand.
This can be used as a shortcut to "git checkout feature/full-feature-name".
Feature branch prefix names may be used for convenience.
diff --git a/git-flow-feature b/git-flow-feature
index a1c2ff8..56dd38d 100644
--- a/git-flow-feature
+++ b/git-flow-feature
@@ -49,6 +49,7 @@
echo " git flow feature track <name>"
echo " git flow feature diff [<name|nameprefix>]"
echo " git flow feature rebase [-i] [<name|nameprefix>]"
+ echo " git flow feature checkout [<name|nameprefix>]"
}
cmd_default() {
@@ -389,6 +390,17 @@
fi
}
+cmd_checkout() {
+ parse_args "$@"
+
+ if [ "$NAME" != "" ]; then
+ expand_nameprefix_arg
+ git checkout "$BRANCH"
+ else
+ die "Name a feature branch explicitly."
+ fi
+}
+
cmd_rebase() {
DEFINE_boolean interactive false 'do an interactive rebase' i
parse_args "$@"