Signed-off-by: Pierre Habouzit <madcoder@debian.org>
---
git branch -r isn't working the way it's supposed to, -r works like -a
because of a too quick migration.
I can resend the squashed patch if you prefer.
builtin-branch.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/builtin-branch.c b/builtin-branch.c
index 03728a9..d6d5cff 100644
--- a/builtin-branch.c
+++ b/builtin-branch.c
@@ -511,7 +511,7 @@ int cmd_branch(int argc, const char **argv, const char *prefix)
int rename = 0, force_rename = 0;
int verbose = 0, abbrev = DEFAULT_ABBREV, detached = 0;
int reflog = 0, track;
- int kinds = REF_LOCAL_BRANCH, kind_remote = 0, kind_local = 0;
+ int kinds = REF_LOCAL_BRANCH, kind_remote = 0, kind_any = 0;
struct option options[] = {
OPT_GROUP("Generic options"),
@@ -522,7 +522,7 @@ int cmd_branch(int argc, const char **argv, const char *prefix)
OPT__ABBREV(&abbrev),
OPT_GROUP("Specific git-branch actions:"),
- OPT_BOOLEAN('a', NULL, &kind_local, "list both remote-tracking and local branches"),
+ OPT_BOOLEAN('a', NULL, &kind_any, "list both remote-tracking and local branches"),
OPT_BOOLEAN('d', NULL, &delete, "delete fully merged branch"),
OPT_BOOLEAN('D', NULL, &force_delete, "delete branch (even if not merged)"),
OPT_BOOLEAN('l', NULL, &reflog, "create the branch's reflog"),
@@ -538,10 +538,10 @@ int cmd_branch(int argc, const char **argv, const char *prefix)
delete |= force_delete;
rename |= force_rename;
- if (kind_remote || kind_local)
- kinds |= REF_REMOTE_BRANCH;
- if (kind_local)
- kinds |= REF_LOCAL_BRANCH;
+ if (kind_remote)
+ kinds = REF_REMOTE_BRANCH;
+ if (kind_any)
+ kinds = REF_REMOTE_BRANCH | REF_LOCAL_BRANCH;
if (abbrev && abbrev < MINIMUM_ABBREV)
abbrev = MINIMUM_ABBREV;
else if (abbrev > 40)
--
1.5.3.4.1351.g1145e-dirty
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html