From: Junio C Hamano Date: Wed, 11 Jan 2006 08:20:25 +0000 (-0800) Subject: show-branch: handle [] globs as well. X-Git-Tag: v1.0.10^2~3 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=87758f975b04233ba058750f7ea8ce63bb67297f;p=git.git show-branch: handle [] globs as well. Earlier only '?' and '*' signalled the command that what the user has given is a glob pattern. This prevented us to say: $ git show-branch 'v0.99.[0-3]' Now we notice '[' as well, so the above would work. Signed-off-by: Junio C Hamano --- diff --git a/show-branch.c b/show-branch.c index 15b196878..1935c448f 100644 --- a/show-branch.c +++ b/show-branch.c @@ -492,7 +492,7 @@ static void append_one_rev(const char *av) append_ref(av, revkey); return; } - if (strchr(av, '*') || strchr(av, '?')) { + if (strchr(av, '*') || strchr(av, '?') || strchr(av, '[')) { /* glob style match */ int saved_matches = ref_name_cnt; match_ref_pattern = av;