Subject: | search .js files |
[ask@g5 /]$ diff -u /usr/bin/ack~ /usr/bin/ack
--- /usr/bin/ack~ 2006-04-16 16:32:11.000000000 -0700
+++ /usr/bin/ack 2006-05-01 05:59:04.000000000 -0700
@@ -42,7 +42,7 @@
our $opt_help = 0;
our %lang;
-our @languages_supported = qw( cc perl php python ruby shell sql );
+our @languages_supported = qw( cc perl php python ruby shell sql javascript );
my %options = (
h => \( our $opt_h = 0 ),
--- /Library/Perl/5.8.6/App/Ack.pm~ 2006-03-28 06:37:34.000000000 -0800
+++ /Library/Perl/5.8.6/App/Ack.pm 2006-05-01 06:01:20.000000000 -0700
@@ -40,6 +40,7 @@
return "ruby" if $filename =~ /\.rb$/;
return "shell" if $filename =~ /\.[ckz]?sh$/;
return "sql" if $filename =~ /\.(sql|ctl)$/;
+ return "javascript" if $filename =~ /\.(js)$/;
if ( $filename !~ /\./ ) {
# No extension? See if it's a shell script