Skip to content

Commit

Permalink
show-branch: handle [] globs as well.
Browse files Browse the repository at this point in the history
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 <junkio@cox.net>
  • Loading branch information
Junio C Hamano committed Jan 11, 2006
1 parent 2c817df commit 87758f9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion show-branch.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit 87758f9

Please sign in to comment.