From: Joey Hess Date: Thu, 25 Oct 2007 08:28:28 +0000 (-0400) Subject: support globbing to match things like git-* X-Git-Tag: 2.43~6 X-Git-Url: http://git.ieval.ro/?a=commitdiff_plain;h=84cbfd03b1483609e1b9fdf8b8b4403533e17748;p=filters.git support globbing to match things like git-* --- diff --git a/fanboy b/fanboy index 743a004..32fe7e3 100755 --- a/fanboy +++ b/fanboy @@ -2,10 +2,16 @@ if (! @ARGV) { @ARGV=qw(linus git linux rebase rebased merge merged cherry-pick - branch branched branches); + branch branched branches git-*); } -my $coolstuff=join("|", map { "\Q$_\E" } reverse sort @ARGV); +my $coolstuff=join("|", + map { + $_=quotemeta($_); + s/\\\*/.*/g; + s/\\\?/./g; + $_; + } reverse sort @ARGV); my $len=0; my $indent="";