Skip to content
Browse files

Undoing the double trunk directory

  • Loading branch information...
0 parents commit c572745b01213c654b670174788ebd4e2fe1a76f petdance committed Aug 7, 2006
Showing with 3,049 additions and 0 deletions.
  1. +330 −0 Ack.pm
  2. +129 −0 Changes
  3. +26 −0 MANIFEST
  4. +13 −0 META.yml
  5. +829 −0 Makefile
  6. +34 −0 Makefile.PL
  7. +829 −0 Makefile.old
  8. +34 −0 README
  9. +260 −0 ack
  10. +11 −0 t/00-load.t
  11. +21 −0 t/filetypes.t
  12. +28 −0 t/find.t
  13. +117 −0 t/interesting.t
  14. +8 −0 t/pod-coverage.t
  15. +9 −0 t/pod.t
  16. +24 −0 t/swamp/Makefile
  17. +11 −0 t/swamp/Makefile.PL
  18. +88 −0 t/swamp/blib/ignore.pir
  19. +11 −0 t/swamp/blib/ignore.pm
  20. +11 −0 t/swamp/blib/ignore.pod
  21. +12 −0 t/swamp/c-header.h
  22. +49 −0 t/swamp/c-source.c
  23. +6 −0 t/swamp/javascript.js
  24. +88 −0 t/swamp/parrot.pir
  25. +11 −0 t/swamp/perl-test.t
  26. +3 −0 t/swamp/perl-without-extension
  27. +11 −0 t/swamp/perl.pl
  28. +11 −0 t/swamp/perl.pm
  29. +11 −0 t/swamp/perl.pod
  30. +24 −0 tags
330 Ack.pm
@@ -0,0 +1,330 @@
+package App::Ack;
+
+use warnings;
+use strict;
+
+=head1 NAME
+
+App::Ack - A container for functions for the ack program
+
+=head1 VERSION
+
+Version 1.24
+
+=cut
+
+our $VERSION = '1.24';
+
+=head1 SYNOPSIS
+
+No user-serviceable parts inside. F<ack> is all that should use this.
+
+=head1 FUNCTIONS
+
+=head2 is_filetype( $filename, $filetype )
+
+Asks whether I<$filename> is of type I<$filetype>.
+
+=cut
+
+sub is_filetype {
+ my $filename = shift;
+ my $wanted_type = shift;
+
+ for my $maybe_type ( filetypes( $filename ) ) {
+ return 1 if $maybe_type eq $wanted_type;
+ }
+
+ return;
+}
+
+our %types;
+our %mappings = (
+ cc => [qw( c h )],
+ css => [qw( css )],
+ javascript => [qw( js )],
+ parrot => [qw( pir pasm pmc ops pod pg tg )],
+ perl => [qw( pl pm pod tt ttml t )],
+ php => [qw( php phpt htm html )],
+ python => [qw( py )],
+ ruby => [qw( rb )],
+ shell => [qw( sh bash csh ksh zsh )],
+ sql => [qw( sql ctl )],
+ yaml => [qw( yaml )],
+);
+
+sub _init_types {
+ while ( my ($type,$exts) = each %mappings ) {
+ for my $ext ( @$exts ) {
+ push( @{$types{$ext}}, $type );
+ }
+ }
+
+ return;
+}
+
+
+=head2 filetypes( $filename )
+
+Returns a list of types that I<$filename> could be. For example, a file
+F<foo.pod> could be "perl" or "parrot".
+
+=cut
+
+sub filetypes {
+ my $filename = shift;
+
+ _init_types() unless keys %types;
+
+ if ( $filename =~ /\.([^.]+)$/ ) {
+ my $ref = $types{lc $1};
+ return $ref ? @$ref : ();
+ }
+
+ # No extension? See if it has a shebang line
+ if ( $filename !~ /\./ ) {
+ my $fh;
+ if ( !open( $fh, "<", $filename ) ) {
+ warn "ack: $filename: $!\n";
+ return;
+ }
+ my $header = <$fh>;
+ close $fh;
+ return unless defined $header;
+ return "perl" if $header =~ /^#!.+\bperl\b/;
+ return "php" if $header =~ /^#!.+\bphp\b/;
+ return "python" if $header =~ /^#!.+\bpython\b/;
+ return "ruby" if $header =~ /^#!.+\bruby\b/;
+ return "shell" if $header =~ /^#!.+\b(ba|c|k|z)?sh\b/;
+ return;
+ }
+
+ return;
+}
+
+=head2 filetypes_supported()
+
+Returns a list of all the types that we can detect.
+
+=cut
+
+sub filetypes_supported {
+ return keys %mappings;
+}
+
+=head2 interesting_files( \&is_interesting, $should_descend, @starting points )
+
+Returns an iterator that walks directories starting with the items
+in I<@starting_points>. If I<$should_descend> is false, don't descend
+into subdirectories. Each file to see if it's interesting is passed to
+I<is_interesting>, which must return true.
+
+All file-finding in this module is adapted from Mark Jason Dominus'
+marvelous I<Higher Order Perl>, page 126.
+
+=cut
+
+sub interesting_files {
+ my $is_interesting = shift;
+ my $should_descend = shift;
+ my @queue = map { _candidate_files($_) } @_;
+
+ return sub {
+ while (@queue) {
+ my $file = shift @queue;
+
+ if (-d $file) {
+ push( @queue, _candidate_files( $file ) ) if $should_descend;
+ }
+ elsif (-f $file) {
+ return $file if $is_interesting->($file);
+ }
+ } # while
+ return;
+ }; # iterator
+}
+
+=head2 _candidate_files( $dir )
+
+Pulls out the files/dirs that might be worth looking into in I<$dir>.
+If I<$dir> is the empty string, then search the current directory.
+This is different than explicitly passing in a ".", because that
+will get prepended to the path names.
+
+=cut
+
+our %ignore_dirs = map { ($_,1) } qw( . .. CVS RCS .svn _darcs blib );
+sub _candidate_files {
+ my $dir = shift;
+
+ my @newfiles;
+
+ # TODO Refactor out the redundancy
+ if ( $dir eq '' ) {
+ my $dh;
+ if ( !opendir $dh, "." ) {
+ warn "ack: in current directory: $!\n";
+ return;
+ }
+
+ @newfiles = grep { !$ignore_dirs{$_} } readdir $dh;
+ }
+ else {
+ return $dir unless -d $dir;
+
+ my $dh;
+ if ( !opendir $dh, $dir ) {
+ warn "ack: $dir: $!\n";
+ return;
+ }
+
+ @newfiles = grep { !$ignore_dirs{$_} } readdir $dh;
+ @newfiles = map { "$dir/$_" } @newfiles;
+ }
+ return @newfiles;
+}
+
+sub _thpppt {
+ my $y = q{_ /|,\\'!.x',=(www)=, U };
+ $y =~ tr/,x!w/\nOo_/;
+ print "$y ack $_[0]!\n" and exit 0;
+}
+
+=head2 show_help()
+
+Dumps the help page to the user.
+
+=cut
+
+sub show_help {
+ my @lines = <DATA>;
+
+ for ( @lines ) {
+ s/(\w+)(\s+)LIST/$1.$2._expand_list($1)/esmx;
+ }
+ print @lines;
+}
+
+sub _expand_list {
+ my $lang = shift;
+
+ my @files = map { ".$_" } @{$mappings{$lang}};
+ my $and = pop @files;
+
+ return @files ? join( ", ", @files ) . " and $and" : $and;
+}
+
+=head1 AUTHOR
+
+Andy Lester, C<< <andy at petdance.com> >>
+
+=head1 BUGS
+
+Please report any bugs or feature requests to
+C<bug-ack at rt.cpan.org>, or through the web interface at
+L<http://rt.cpan.org/NoAuth/ReportBug.html?Queue=ack>.
+I will be notified, and then you'll automatically be notified of progress on
+your bug as I make changes.
+
+=head1 SUPPORT
+
+The App::Ack module isn't very interesting to users. However, you may
+find useful information about this distribution at:
+
+=over 4
+
+=item * AnnoCPAN: Annotated CPAN documentation
+
+L<http://annocpan.org/dist/ack>
+
+=item * CPAN Ratings
+
+L<http://cpanratings.perl.org/d/ack>
+
+=item * RT: CPAN's request tracker
+
+L<http://rt.cpan.org/NoAuth/Bugs.html?Dist=ack>
+
+=item * Search CPAN
+
+L<http://search.cpan.org/dist/ack>
+
+=item * Subversion repository
+
+L<http://ack.googlecode.com/svn/>
+
+=back
+
+=head1 ACKNOWLEDGEMENTS
+
+=head1 COPYRIGHT & LICENSE
+
+Copyright 2005-2006 Andy Lester, all rights reserved.
+
+This program is free software; you can redistribute it and/or modify it
+under the same terms as Perl itself.
+
+=cut
+
+1; # End of App::Ack
+
+__DATA__
+Usage: ack [OPTION]... PATTERN [FILES]
+Search for PATTERN in each source file in the tree from cwd on down.
+If [FILES] is specified, then only those files/directories are checked.
+ack may also search STDIN, but only if no FILES are specified, or if
+one of FILES is "-".
+
+Default switches may be specified in ACK_SWITCHES environment variable.
+
+Example: ack -i select
+
+Searching:
+ -i ignore case distinctions
+ -v invert match: select non-matching lines
+ -w force PATTERN to match only whole words
+
+Search output:
+ -l only print filenames containing matches
+ -o show only the part of a line matching PATTERN
+ -m=NUM stop after NUM matches
+ -H print the filename for each match
+ -h suppress the prefixing filename on output
+ -c, --count show number of lines matching per file
+ --[no]group print a blank line between each file's matches
+ (default: on unless output is redirected)
+ --[no]color highlight the matching text (default: on unless
+ output is redirected, or on Windows)
+
+File finding:
+ -f only print the files found, without searching.
+ The PATTERN must not be specified.
+
+File inclusion/exclusion:
+ -n No descending into subdirectories
+ -a, --all All files, regardless of extension
+ (but still skips RCS, CVS, .svn, _darcs and blib dirs)
+ --[no]cc LIST
+ --[no]javascript LIST
+ --[no]js same as --[no]javascript
+ --[no]parrot LIST
+ --[no]perl LIST
+ --[no]php LIST
+ --[no]python LIST
+ --[no]ruby LIST
+ --[no]shell LIST
+ --[no]sql LIST
+ --[no]yaml LIST
+
+Miscellaneous:
+ --help this help
+ --version display version
+ --thpppt Bill the Cat
+
+
+GOTCHAS:
+Note that FILES must still match valid selection rules. For example,
+
+ ack something --perl foo.rb
+
+will search nothing, because foo.rb is a Ruby file.
129 Changes
@@ -0,0 +1,129 @@
+Revision history for ack
+
+NEXT
+ [ENHANCEMENTS]
+ * Added .css support.
+
+1.24 Sun Jul 16 01:10:44 CDT 2006
+ [ENHANCEMENTS]
+ * Now ignores files beginning with a dot, unless the -a/--all
+ flag is specified.
+ * Removed all the symbol exporting in App::Ack, so should
+ be microscopically faster. Of course, if I really wanted
+ it faster, I'd have the entire app in one file.
+
+ [FIXES]
+ * Smarter about detecting shebang lines in extensionless
+ files.
+ * The -a/--all flag now is indeed EVERY file. Until now,
+ it would still have ignored files ending with a tilde.
+
+
+1.22 Tue Jul 4 22:04:38 CDT 2006
+ [FIXES]
+ * t/filetypes.t would fail under 5.6.1
+
+ [ENHANCEMENTS]
+ * Added -c to show number of lines match
+
+
+1.20 Wed Jun 7 22:17:39 CDT 2006
+ [ENHANCEMENTS]
+ * Added --yaml
+ * Added --thpppt flag
+
+
+1.17_02 Tue Jun 6 14:32:38 CDT 2006
+ [FIXES]
+ * The -v flag would print out empty blank lines when it
+ shouldn't. Now it works.
+
+ [ENHANCEMENTS]
+ * Added the -H flag to always print filenames
+
+ * Filenames no longer have "./" prepended unless you specify
+ "." as a directory to search.
+
+
+1.17_01 Mon Jun 5 12:04:38 CDT 2006
+ [FIXES]
+ * Starting points for files can be files, not just directories.
+ This broke in 1.16.
+
+ [ENHANCEMENTS]
+ * ack can now read from STDIN as a filter, like any good program.
+
+1.16 Fri Jun 2 23:50:10 CDT 2006
+ [FIXES]
+ * The -n flag was not working. Using -n would find no files
+ at all. And added some more unit tests to make sure I don't
+ screw it up again.
+
+1.14 Tue May 30 23:12:43 CDT 2006
+ [ENHANCEMENTS]
+ * Added -f flag to only show the files that would be searched,
+ instead of actually searching them. This means that you can
+ get an easy way to get a list of all the Perl files in the
+ current directory, for example, by doing
+
+ ack -f --perl
+
+ Or in multiple directories
+
+ ack -f --perl thisdir thatdir
+
+ [FIXES]
+ * Added back -a as a synonym for --all.
+
+1.12 Wed May 10 11:13:42 CDT 2006
+ [FIXES]
+ * Was not skipping directories it should have been. Now it does.
+
+1.10 Thu May 4 16:11:38 CDT 2006
+ [ENHANCEMENTS]
+ * Added --parrot support. Thanks, Jerry Gay.
+
+ * No longer defaults to ANSI highlighting on Windows. Thanks
+ again, Jerry.
+
+ * Added support for ACK_SWITCHES environment variable.
+
+1.08 May 01 2006
+ [ENHANCEMENTS]
+ * Now supports argument bundling. "ack -i -l" can now be done as
+ "ack -il". Thanks, Pete Krawczyk.
+
+ * Added --javascript support, plus a --js version to save your
+ weary fingers. Thanks, Ask.
+
+1.06 Tue Mar 28 08:37:02 CST 2006
+ [FIXES]
+ * Now handles filenames that start with ">" or "<".
+ * Failing to open a file is now a warning, instead of fatal.
+
+1.04 Wed Jan 25 22:51:11 CST 2006
+ [ENHANCEMENTS]
+ * Now skips blib and RCS as well as CVS and .svn directories.
+ * Added support for Python and Ruby.
+
+1.02 Wed Dec 14 13:13:19 CST 2005
+ [FIXES]
+ * Fixed a mind-blowingly dumb bug. The --all flag would search
+ no files at all.
+
+1.00 Wed Dec 7 09:30:25 CST 2005
+ [ENHANCEMENTS]
+ * Added support for finding C programs (--cc)
+
+ * Removed the --only option. It's now smart enough to know
+ that if, for example, you say --perl, you only want Perl stuff,
+ and that if you say --noperl, you want everything BUT Perl.
+
+ * Removed the --exec option, which is irrelevant if you use
+ xargs like you should. I added --exec before I understood what
+ xargs did.
+
+0.90 Fri Dec 2 11:12:44 CST 2005
+ First version, released on an unsuspecting world. It's been
+ used at FLR for years, but I'm now releasing it in the wild.
+
26 MANIFEST
@@ -0,0 +1,26 @@
+ack
+Ack.pm
+Changes
+MANIFEST
+Makefile.PL
+README
+t/00-load.t
+t/filetypes.t
+t/find.t
+t/interesting.t
+t/pod-coverage.t
+t/pod.t
+t/swamp/c-header.h
+t/swamp/c-source.c
+t/swamp/javascript.js
+t/swamp/Makefile
+t/swamp/Makefile.PL
+t/swamp/parrot.pir
+t/swamp/perl-test.t
+t/swamp/perl-without-extension
+t/swamp/perl.pl
+t/swamp/perl.pm
+t/swamp/perl.pod
+t/swamp/blib/ignore.pod
+t/swamp/blib/ignore.pm
+t/swamp/blib/ignore.pir
13 META.yml
@@ -0,0 +1,13 @@
+# http://module-build.sourceforge.net/META-spec.html
+#XXXXXXX This is a prototype!!! It will change in the future!!! XXXXX#
+name: ack
+version: 1.17_02
+version_from: Ack.pm
+installdirs: site
+requires:
+ Getopt::Long: 0
+ Term::ANSIColor: 0
+ Test::More: 0
+
+distribution_type: module
+generated_by: ExtUtils::MakeMaker version 6.17
829 Makefile
@@ -0,0 +1,829 @@
+# This Makefile is for the ack extension to perl.
+#
+# It was generated automatically by MakeMaker version
+# 6.30_01 (Revision: 1) from the contents of
+# Makefile.PL. Don't edit this file, edit Makefile.PL instead.
+#
+# ANY CHANGES MADE HERE WILL BE LOST!
+#
+# MakeMaker ARGV: ()
+#
+# MakeMaker Parameters:
+
+# ABSTRACT => q[A grep-like program specifically for large source trees]
+# AUTHOR => q[Andy Lester <andy@petdance.com>]
+# EXE_FILES => [q[ack]]
+# MAN3PODS => { Ack.pm=>q[$(INST_MAN3DIR)/Ack.$(MAN3EXT)] }
+# NAME => q[ack]
+# PM => { Ack.pm=>q[$(INST_LIBDIR)/App/Ack.pm] }
+# PREREQ_PM => { Test::More=>q[0], Getopt::Long=>q[0], Term::ANSIColor=>q[0] }
+# VERSION_FROM => q[Ack.pm]
+# clean => { FILES=>q[ack-*] }
+# dist => { COMPRESS=>q[gzip -9f], SUFFIX=>q[gz] }
+
+# --- MakeMaker post_initialize section:
+
+
+# --- MakeMaker const_config section:
+
+# These definitions are from config.sh (via /System/Library/Perl/5.8.6/darwin-thread-multi-2level/Config.pm)
+
+# They may have been overridden via Makefile.PL or on the command line
+AR = ar
+CC = cc
+CCCDLFLAGS =
+CCDLFLAGS =
+DLEXT = bundle
+DLSRC = dl_dlopen.xs
+EXE_EXT =
+FULL_AR = /usr/bin/ar
+LD = env MACOSX_DEPLOYMENT_TARGET=10.3 cc
+LDDLFLAGS = -bundle -undefined dynamic_lookup -L/usr/local/lib
+LDFLAGS = -L/usr/local/lib
+LIBC = /usr/lib/libc.dylib
+LIB_EXT = .a
+OBJ_EXT = .o
+OSNAME = darwin
+OSVERS = 8.0
+RANLIB = /usr/bin/ar ts
+SITELIBEXP = /Library/Perl/5.8.6
+SITEARCHEXP = /Library/Perl/5.8.6/darwin-thread-multi-2level
+SO = dylib
+VENDORARCHEXP = /Network/Library/Perl/5.8.6/darwin-thread-multi-2level
+VENDORLIBEXP = /Network/Library/Perl/5.8.6
+
+
+# --- MakeMaker constants section:
+AR_STATIC_ARGS = cr
+DIRFILESEP = /
+DFSEP = $(DIRFILESEP)
+NAME = ack
+NAME_SYM = ack
+VERSION = 1.24
+VERSION_MACRO = VERSION
+VERSION_SYM = 1_24
+DEFINE_VERSION = -D$(VERSION_MACRO)=\"$(VERSION)\"
+XS_VERSION = 1.24
+XS_VERSION_MACRO = XS_VERSION
+XS_DEFINE_VERSION = -D$(XS_VERSION_MACRO)=\"$(XS_VERSION)\"
+INST_ARCHLIB = blib/arch
+INST_SCRIPT = blib/script
+INST_BIN = blib/bin
+INST_LIB = blib/lib
+INST_MAN1DIR = blib/man1
+INST_MAN3DIR = blib/man3
+MAN1EXT = 1
+MAN3EXT = 3pm
+INSTALLDIRS = site
+DESTDIR =
+PREFIX = $(SITEPREFIX)
+PERLPREFIX = /
+SITEPREFIX = /usr/local
+VENDORPREFIX = /usr/local
+INSTALLPRIVLIB = /System/Library/Perl/5.8.6
+DESTINSTALLPRIVLIB = $(DESTDIR)$(INSTALLPRIVLIB)
+INSTALLSITELIB = /Library/Perl/5.8.6
+DESTINSTALLSITELIB = $(DESTDIR)$(INSTALLSITELIB)
+INSTALLVENDORLIB = /Network/Library/Perl/5.8.6
+DESTINSTALLVENDORLIB = $(DESTDIR)$(INSTALLVENDORLIB)
+INSTALLARCHLIB = /System/Library/Perl/5.8.6/darwin-thread-multi-2level
+DESTINSTALLARCHLIB = $(DESTDIR)$(INSTALLARCHLIB)
+INSTALLSITEARCH = /Library/Perl/5.8.6/darwin-thread-multi-2level
+DESTINSTALLSITEARCH = $(DESTDIR)$(INSTALLSITEARCH)
+INSTALLVENDORARCH = /Network/Library/Perl/5.8.6/darwin-thread-multi-2level
+DESTINSTALLVENDORARCH = $(DESTDIR)$(INSTALLVENDORARCH)
+INSTALLBIN = /usr/bin
+DESTINSTALLBIN = $(DESTDIR)$(INSTALLBIN)
+INSTALLSITEBIN = /usr/local/bin
+DESTINSTALLSITEBIN = $(DESTDIR)$(INSTALLSITEBIN)
+INSTALLVENDORBIN = /usr/local/bin
+DESTINSTALLVENDORBIN = $(DESTDIR)$(INSTALLVENDORBIN)
+INSTALLSCRIPT = /usr/bin
+DESTINSTALLSCRIPT = $(DESTDIR)$(INSTALLSCRIPT)
+INSTALLMAN1DIR = /usr/share/man/man1
+DESTINSTALLMAN1DIR = $(DESTDIR)$(INSTALLMAN1DIR)
+INSTALLSITEMAN1DIR = /usr/local/man/man1
+DESTINSTALLSITEMAN1DIR = $(DESTDIR)$(INSTALLSITEMAN1DIR)
+INSTALLVENDORMAN1DIR = /usr/local/man/man1
+DESTINSTALLVENDORMAN1DIR = $(DESTDIR)$(INSTALLVENDORMAN1DIR)
+INSTALLMAN3DIR = /usr/share/man/man3
+DESTINSTALLMAN3DIR = $(DESTDIR)$(INSTALLMAN3DIR)
+INSTALLSITEMAN3DIR = /usr/local/man/man3
+DESTINSTALLSITEMAN3DIR = $(DESTDIR)$(INSTALLSITEMAN3DIR)
+INSTALLVENDORMAN3DIR = /usr/local/man/man3
+DESTINSTALLVENDORMAN3DIR = $(DESTDIR)$(INSTALLVENDORMAN3DIR)
+PERL_LIB = /System/Library/Perl/5.8.6
+PERL_ARCHLIB = /System/Library/Perl/5.8.6/darwin-thread-multi-2level
+LIBPERL_A = libperl.a
+FIRST_MAKEFILE = Makefile
+MAKEFILE_OLD = Makefile.old
+MAKE_APERL_FILE = Makefile.aperl
+PERLMAINCC = $(CC)
+PERL_INC = /System/Library/Perl/5.8.6/darwin-thread-multi-2level/CORE
+PERL = /usr/local/bin/perl
+FULLPERL = /usr/local/bin/perl
+ABSPERL = $(PERL)
+PERLRUN = $(PERL)
+FULLPERLRUN = $(FULLPERL)
+ABSPERLRUN = $(ABSPERL)
+PERLRUNINST = $(PERLRUN) "-I$(INST_ARCHLIB)" "-I$(INST_LIB)"
+FULLPERLRUNINST = $(FULLPERLRUN) "-I$(INST_ARCHLIB)" "-I$(INST_LIB)"
+ABSPERLRUNINST = $(ABSPERLRUN) "-I$(INST_ARCHLIB)" "-I$(INST_LIB)"
+PERL_CORE = 0
+PERM_RW = 644
+PERM_RWX = 755
+
+MAKEMAKER = /System/Library/Perl/5.8.6/ExtUtils/MakeMaker.pm
+MM_VERSION = 6.30_01
+MM_REVISION = 1
+
+# FULLEXT = Pathname for extension directory (eg Foo/Bar/Oracle).
+# BASEEXT = Basename part of FULLEXT. May be just equal FULLEXT. (eg Oracle)
+# PARENT_NAME = NAME without BASEEXT and no trailing :: (eg Foo::Bar)
+# DLBASE = Basename part of dynamic library. May be just equal BASEEXT.
+MAKE = make
+FULLEXT = ack
+BASEEXT = ack
+PARENT_NAME =
+DLBASE = $(BASEEXT)
+VERSION_FROM = Ack.pm
+OBJECT =
+LDFROM = $(OBJECT)
+LINKTYPE = dynamic
+BOOTDEP =
+
+# Handy lists of source code files:
+XS_FILES =
+C_FILES =
+O_FILES =
+H_FILES =
+MAN1PODS = ack
+MAN3PODS = Ack.pm
+
+# Where is the Config information that we are using/depend on
+CONFIGDEP = $(PERL_ARCHLIB)$(DFSEP)Config.pm $(PERL_INC)$(DFSEP)config.h
+
+# Where to build things
+INST_LIBDIR = $(INST_LIB)
+INST_ARCHLIBDIR = $(INST_ARCHLIB)
+
+INST_AUTODIR = $(INST_LIB)/auto/$(FULLEXT)
+INST_ARCHAUTODIR = $(INST_ARCHLIB)/auto/$(FULLEXT)
+
+INST_STATIC =
+INST_DYNAMIC =
+INST_BOOT =
+
+# Extra linker info
+EXPORT_LIST =
+PERL_ARCHIVE =
+PERL_ARCHIVE_AFTER =
+
+
+TO_INST_PM = Ack.pm
+
+PM_TO_BLIB = Ack.pm \
+ $(INST_LIBDIR)/App/Ack.pm
+
+
+# --- MakeMaker platform_constants section:
+MM_Unix_VERSION = 1.50_01
+PERL_MALLOC_DEF = -DPERL_EXTMALLOC_DEF -Dmalloc=Perl_malloc -Dfree=Perl_mfree -Drealloc=Perl_realloc -Dcalloc=Perl_calloc
+
+
+# --- MakeMaker tool_autosplit section:
+# Usage: $(AUTOSPLITFILE) FileToSplit AutoDirToSplitInto
+AUTOSPLITFILE = $(ABSPERLRUN) -e 'use AutoSplit; autosplit($$ARGV[0], $$ARGV[1], 0, 1, 1)' --
+
+
+
+# --- MakeMaker tool_xsubpp section:
+
+
+# --- MakeMaker tools_other section:
+SHELL = /bin/sh
+CHMOD = chmod
+CP = cp
+MV = mv
+NOOP = $(SHELL) -c true
+NOECHO = @
+RM_F = rm -f
+RM_RF = rm -rf
+TEST_F = test -f
+TOUCH = touch
+UMASK_NULL = umask 0
+DEV_NULL = > /dev/null 2>&1
+MKPATH = $(ABSPERLRUN) "-MExtUtils::Command" -e mkpath
+EQUALIZE_TIMESTAMP = $(ABSPERLRUN) "-MExtUtils::Command" -e eqtime
+ECHO = echo
+ECHO_N = echo -n
+UNINST = 0
+VERBINST = 0
+MOD_INSTALL = $(ABSPERLRUN) -MExtUtils::Install -e 'install({@ARGV}, '\''$(VERBINST)'\'', 0, '\''$(UNINST)'\'');' --
+DOC_INSTALL = $(ABSPERLRUN) "-MExtUtils::Command::MM" -e perllocal_install
+UNINSTALL = $(ABSPERLRUN) "-MExtUtils::Command::MM" -e uninstall
+WARN_IF_OLD_PACKLIST = $(ABSPERLRUN) "-MExtUtils::Command::MM" -e warn_if_old_packlist
+MACROSTART =
+MACROEND =
+USEMAKEFILE = -f
+FIXIN = $(PERLRUN) "-MExtUtils::MY" -e "MY->fixin(shift)"
+
+
+# --- MakeMaker makemakerdflt section:
+makemakerdflt: all
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker dist section:
+TAR = tar
+TARFLAGS = cvf
+ZIP = zip
+ZIPFLAGS = -r
+COMPRESS = gzip -9f
+SUFFIX = gz
+SHAR = shar
+PREOP = $(NOECHO) $(NOOP)
+POSTOP = $(NOECHO) $(NOOP)
+TO_UNIX = $(NOECHO) $(NOOP)
+CI = ci -u
+RCS_LABEL = rcs -Nv$(VERSION_SYM): -q
+DIST_CP = best
+DIST_DEFAULT = tardist
+DISTNAME = ack
+DISTVNAME = ack-1.24
+
+
+# --- MakeMaker macro section:
+
+
+# --- MakeMaker depend section:
+
+
+# --- MakeMaker cflags section:
+
+
+# --- MakeMaker const_loadlibs section:
+
+
+# --- MakeMaker const_cccmd section:
+
+
+# --- MakeMaker post_constants section:
+
+
+# --- MakeMaker pasthru section:
+
+PASTHRU = LIBPERL_A="$(LIBPERL_A)"\
+ LINKTYPE="$(LINKTYPE)"\
+ PREFIX="$(PREFIX)"
+
+
+# --- MakeMaker special_targets section:
+.SUFFIXES : .xs .c .C .cpp .i .s .cxx .cc $(OBJ_EXT)
+
+.PHONY: all config static dynamic test linkext manifest blibdirs clean realclean disttest distdir
+
+
+
+# --- MakeMaker c_o section:
+
+
+# --- MakeMaker xs_c section:
+
+
+# --- MakeMaker xs_o section:
+
+
+# --- MakeMaker top_targets section:
+all :: pure_all manifypods
+ $(NOECHO) $(NOOP)
+
+
+pure_all :: config pm_to_blib subdirs linkext
+ $(NOECHO) $(NOOP)
+
+subdirs :: $(MYEXTLIB)
+ $(NOECHO) $(NOOP)
+
+config :: $(FIRST_MAKEFILE) blibdirs
+ $(NOECHO) $(NOOP)
+
+help :
+ perldoc ExtUtils::MakeMaker
+
+
+# --- MakeMaker blibdirs section:
+blibdirs : $(INST_LIBDIR)$(DFSEP).exists $(INST_ARCHLIB)$(DFSEP).exists $(INST_AUTODIR)$(DFSEP).exists $(INST_ARCHAUTODIR)$(DFSEP).exists $(INST_BIN)$(DFSEP).exists $(INST_SCRIPT)$(DFSEP).exists $(INST_MAN1DIR)$(DFSEP).exists $(INST_MAN3DIR)$(DFSEP).exists
+ $(NOECHO) $(NOOP)
+
+# Backwards compat with 6.18 through 6.25
+blibdirs.ts : blibdirs
+ $(NOECHO) $(NOOP)
+
+$(INST_LIBDIR)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_LIBDIR)
+ $(NOECHO) $(CHMOD) 755 $(INST_LIBDIR)
+ $(NOECHO) $(TOUCH) $(INST_LIBDIR)$(DFSEP).exists
+
+$(INST_ARCHLIB)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_ARCHLIB)
+ $(NOECHO) $(CHMOD) 755 $(INST_ARCHLIB)
+ $(NOECHO) $(TOUCH) $(INST_ARCHLIB)$(DFSEP).exists
+
+$(INST_AUTODIR)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_AUTODIR)
+ $(NOECHO) $(CHMOD) 755 $(INST_AUTODIR)
+ $(NOECHO) $(TOUCH) $(INST_AUTODIR)$(DFSEP).exists
+
+$(INST_ARCHAUTODIR)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_ARCHAUTODIR)
+ $(NOECHO) $(CHMOD) 755 $(INST_ARCHAUTODIR)
+ $(NOECHO) $(TOUCH) $(INST_ARCHAUTODIR)$(DFSEP).exists
+
+$(INST_BIN)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_BIN)
+ $(NOECHO) $(CHMOD) 755 $(INST_BIN)
+ $(NOECHO) $(TOUCH) $(INST_BIN)$(DFSEP).exists
+
+$(INST_SCRIPT)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_SCRIPT)
+ $(NOECHO) $(CHMOD) 755 $(INST_SCRIPT)
+ $(NOECHO) $(TOUCH) $(INST_SCRIPT)$(DFSEP).exists
+
+$(INST_MAN1DIR)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_MAN1DIR)
+ $(NOECHO) $(CHMOD) 755 $(INST_MAN1DIR)
+ $(NOECHO) $(TOUCH) $(INST_MAN1DIR)$(DFSEP).exists
+
+$(INST_MAN3DIR)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_MAN3DIR)
+ $(NOECHO) $(CHMOD) 755 $(INST_MAN3DIR)
+ $(NOECHO) $(TOUCH) $(INST_MAN3DIR)$(DFSEP).exists
+
+
+
+# --- MakeMaker linkext section:
+
+linkext :: $(LINKTYPE)
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker dlsyms section:
+
+
+# --- MakeMaker dynamic section:
+
+dynamic :: $(FIRST_MAKEFILE) $(INST_DYNAMIC) $(INST_BOOT)
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker dynamic_bs section:
+
+BOOTSTRAP =
+
+
+# --- MakeMaker dynamic_lib section:
+
+
+# --- MakeMaker static section:
+
+## $(INST_PM) has been moved to the all: target.
+## It remains here for awhile to allow for old usage: "make static"
+static :: $(FIRST_MAKEFILE) $(INST_STATIC)
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker static_lib section:
+
+
+# --- MakeMaker manifypods section:
+
+POD2MAN_EXE = $(PERLRUN) "-MExtUtils::Command::MM" -e pod2man "--"
+POD2MAN = $(POD2MAN_EXE)
+
+
+manifypods : pure_all \
+ ack \
+ Ack.pm \
+ Ack.pm
+ $(NOECHO) $(POD2MAN) --section=1 --perm_rw=$(PERM_RW) \
+ ack $(INST_MAN1DIR)/ack.$(MAN1EXT)
+ $(NOECHO) $(POD2MAN) --section=3 --perm_rw=$(PERM_RW) \
+ Ack.pm $(INST_MAN3DIR)/Ack.$(MAN3EXT)
+
+
+
+
+# --- MakeMaker processPL section:
+
+
+# --- MakeMaker installbin section:
+
+EXE_FILES = ack
+
+pure_all :: $(INST_SCRIPT)/ack
+ $(NOECHO) $(NOOP)
+
+realclean ::
+ $(RM_F) \
+ $(INST_SCRIPT)/ack
+
+$(INST_SCRIPT)/ack : ack $(FIRST_MAKEFILE) $(INST_SCRIPT)$(DFSEP).exists $(INST_BIN)$(DFSEP).exists
+ $(NOECHO) $(RM_F) $(INST_SCRIPT)/ack
+ $(CP) ack $(INST_SCRIPT)/ack
+ $(FIXIN) $(INST_SCRIPT)/ack
+ -$(NOECHO) $(CHMOD) $(PERM_RWX) $(INST_SCRIPT)/ack
+
+
+
+# --- MakeMaker subdirs section:
+
+# none
+
+# --- MakeMaker clean_subdirs section:
+clean_subdirs :
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker clean section:
+
+# Delete temporary files but do not touch installed files. We don't delete
+# the Makefile here so a later make realclean still has a makefile to use.
+
+clean :: clean_subdirs
+ - $(RM_F) \
+ *$(LIB_EXT) core \
+ core.[0-9] $(INST_ARCHAUTODIR)/extralibs.all \
+ core.[0-9][0-9] $(BASEEXT).bso \
+ pm_to_blib.ts core.[0-9][0-9][0-9][0-9] \
+ $(BASEEXT).x $(BOOTSTRAP) \
+ perl$(EXE_EXT) tmon.out \
+ *$(OBJ_EXT) pm_to_blib \
+ $(INST_ARCHAUTODIR)/extralibs.ld blibdirs.ts \
+ core.[0-9][0-9][0-9][0-9][0-9] *perl.core \
+ core.*perl.*.? $(MAKE_APERL_FILE) \
+ perl $(BASEEXT).def \
+ core.[0-9][0-9][0-9] mon.out \
+ lib$(BASEEXT).def perlmain.c \
+ perl.exe so_locations \
+ $(BASEEXT).exp
+ - $(RM_RF) \
+ ack-* blib
+ - $(MV) $(FIRST_MAKEFILE) $(MAKEFILE_OLD) $(DEV_NULL)
+
+
+# --- MakeMaker realclean_subdirs section:
+realclean_subdirs :
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker realclean section:
+# Delete temporary files (via clean) and also delete dist files
+realclean purge :: clean realclean_subdirs
+ - $(RM_F) \
+ $(MAKEFILE_OLD) $(FIRST_MAKEFILE)
+ - $(RM_RF) \
+ $(DISTVNAME)
+
+
+# --- MakeMaker metafile section:
+metafile : create_distdir
+ $(NOECHO) $(ECHO) Generating META.yml
+ $(NOECHO) $(ECHO) '--- #YAML:1.0' > META_new.yml
+ $(NOECHO) $(ECHO) 'name: ack' >> META_new.yml
+ $(NOECHO) $(ECHO) 'version: 1.24' >> META_new.yml
+ $(NOECHO) $(ECHO) 'abstract: A grep-like program specifically for large source trees' >> META_new.yml
+ $(NOECHO) $(ECHO) 'license: unknown' >> META_new.yml
+ $(NOECHO) $(ECHO) 'generated_by: ExtUtils::MakeMaker version 6.30_01' >> META_new.yml
+ $(NOECHO) $(ECHO) 'author: Andy Lester <andy@petdance.com>' >> META_new.yml
+ $(NOECHO) $(ECHO) 'distribution_type: module' >> META_new.yml
+ $(NOECHO) $(ECHO) 'requires: ' >> META_new.yml
+ $(NOECHO) $(ECHO) ' Getopt::Long: 0' >> META_new.yml
+ $(NOECHO) $(ECHO) ' Term::ANSIColor: 0' >> META_new.yml
+ $(NOECHO) $(ECHO) ' Test::More: 0' >> META_new.yml
+ $(NOECHO) $(ECHO) 'meta-spec:' >> META_new.yml
+ $(NOECHO) $(ECHO) ' url: <http://module-build.sourceforge.net/META-spec-new.html>;' >> META_new.yml
+ $(NOECHO) $(ECHO) ' version: 1.1' >> META_new.yml
+ -$(NOECHO) $(MV) META_new.yml $(DISTVNAME)/META.yml
+
+
+# --- MakeMaker signature section:
+signature :
+ cpansign -s
+
+
+# --- MakeMaker dist_basics section:
+distclean :: realclean distcheck
+ $(NOECHO) $(NOOP)
+
+distcheck :
+ $(PERLRUN) "-MExtUtils::Manifest=fullcheck" -e fullcheck
+
+skipcheck :
+ $(PERLRUN) "-MExtUtils::Manifest=skipcheck" -e skipcheck
+
+manifest :
+ $(PERLRUN) "-MExtUtils::Manifest=mkmanifest" -e mkmanifest
+
+veryclean : realclean
+ $(RM_F) *~ *.orig */*~ */*.orig
+
+
+
+# --- MakeMaker dist_core section:
+
+dist : $(DIST_DEFAULT) $(FIRST_MAKEFILE)
+ $(NOECHO) $(ABSPERLRUN) -l -e 'print '\''Warning: Makefile possibly out of date with $(VERSION_FROM)'\''' \
+ -e ' if -e '\''$(VERSION_FROM)'\'' and -M '\''$(VERSION_FROM)'\'' < -M '\''$(FIRST_MAKEFILE)'\'';' --
+
+tardist : $(DISTVNAME).tar$(SUFFIX)
+ $(NOECHO) $(NOOP)
+
+uutardist : $(DISTVNAME).tar$(SUFFIX)
+ uuencode $(DISTVNAME).tar$(SUFFIX) $(DISTVNAME).tar$(SUFFIX) > $(DISTVNAME).tar$(SUFFIX)_uu
+
+$(DISTVNAME).tar$(SUFFIX) : distdir
+ $(PREOP)
+ $(TO_UNIX)
+ $(TAR) $(TARFLAGS) $(DISTVNAME).tar $(DISTVNAME)
+ $(RM_RF) $(DISTVNAME)
+ $(COMPRESS) $(DISTVNAME).tar
+ $(POSTOP)
+
+zipdist : $(DISTVNAME).zip
+ $(NOECHO) $(NOOP)
+
+$(DISTVNAME).zip : distdir
+ $(PREOP)
+ $(ZIP) $(ZIPFLAGS) $(DISTVNAME).zip $(DISTVNAME)
+ $(RM_RF) $(DISTVNAME)
+ $(POSTOP)
+
+shdist : distdir
+ $(PREOP)
+ $(SHAR) $(DISTVNAME) > $(DISTVNAME).shar
+ $(RM_RF) $(DISTVNAME)
+ $(POSTOP)
+
+
+# --- MakeMaker distdir section:
+create_distdir :
+ $(RM_RF) $(DISTVNAME)
+ $(PERLRUN) "-MExtUtils::Manifest=manicopy,maniread" \
+ -e "manicopy(maniread(),'$(DISTVNAME)', '$(DIST_CP)');"
+
+distdir : create_distdir distmeta
+ $(NOECHO) $(NOOP)
+
+
+
+# --- MakeMaker dist_test section:
+disttest : distdir
+ cd $(DISTVNAME) && $(ABSPERLRUN) Makefile.PL
+ cd $(DISTVNAME) && $(MAKE) $(PASTHRU)
+ cd $(DISTVNAME) && $(MAKE) test $(PASTHRU)
+
+
+
+# --- MakeMaker dist_ci section:
+
+ci :
+ $(PERLRUN) "-MExtUtils::Manifest=maniread" \
+ -e "@all = keys %{ maniread() };" \
+ -e "print(qq{Executing $(CI) @all\n}); system(qq{$(CI) @all});" \
+ -e "print(qq{Executing $(RCS_LABEL) ...\n}); system(qq{$(RCS_LABEL) @all});"
+
+
+# --- MakeMaker distmeta section:
+distmeta : create_distdir metafile
+ $(NOECHO) cd $(DISTVNAME) && $(ABSPERLRUN) -MExtUtils::Manifest=maniadd -e 'eval { maniadd({q{META.yml} => q{Module meta-data (added by MakeMaker)}}) } ' \
+ -e ' or print "Could not add META.yml to MANIFEST: $${'\''@'\''}\n"' --
+
+
+
+# --- MakeMaker distsignature section:
+distsignature : create_distdir
+ $(NOECHO) cd $(DISTVNAME) && $(ABSPERLRUN) -MExtUtils::Manifest=maniadd -e 'eval { maniadd({q{SIGNATURE} => q{Public-key signature (added by MakeMaker)}}) } ' \
+ -e ' or print "Could not add SIGNATURE to MANIFEST: $${'\''@'\''}\n"' --
+ $(NOECHO) cd $(DISTVNAME) && $(TOUCH) SIGNATURE
+ cd $(DISTVNAME) && cpansign -s
+
+
+
+# --- MakeMaker install section:
+
+install :: all pure_install doc_install
+ $(NOECHO) $(NOOP)
+
+install_perl :: all pure_perl_install doc_perl_install
+ $(NOECHO) $(NOOP)
+
+install_site :: all pure_site_install doc_site_install
+ $(NOECHO) $(NOOP)
+
+install_vendor :: all pure_vendor_install doc_vendor_install
+ $(NOECHO) $(NOOP)
+
+pure_install :: pure_$(INSTALLDIRS)_install
+ $(NOECHO) $(NOOP)
+
+doc_install :: doc_$(INSTALLDIRS)_install
+ $(NOECHO) $(NOOP)
+
+pure__install : pure_site_install
+ $(NOECHO) $(ECHO) INSTALLDIRS not defined, defaulting to INSTALLDIRS=site
+
+doc__install : doc_site_install
+ $(NOECHO) $(ECHO) INSTALLDIRS not defined, defaulting to INSTALLDIRS=site
+
+pure_perl_install ::
+ $(NOECHO) $(MOD_INSTALL) \
+ read $(PERL_ARCHLIB)/auto/$(FULLEXT)/.packlist \
+ write $(DESTINSTALLARCHLIB)/auto/$(FULLEXT)/.packlist \
+ $(INST_LIB) $(DESTINSTALLPRIVLIB) \
+ $(INST_ARCHLIB) $(DESTINSTALLARCHLIB) \
+ $(INST_BIN) $(DESTINSTALLBIN) \
+ $(INST_SCRIPT) $(DESTINSTALLSCRIPT) \
+ $(INST_MAN1DIR) $(DESTINSTALLMAN1DIR) \
+ $(INST_MAN3DIR) $(DESTINSTALLMAN3DIR)
+ $(NOECHO) $(WARN_IF_OLD_PACKLIST) \
+ $(SITEARCHEXP)/auto/$(FULLEXT)
+
+
+pure_site_install ::
+ $(NOECHO) $(MOD_INSTALL) \
+ read $(SITEARCHEXP)/auto/$(FULLEXT)/.packlist \
+ write $(DESTINSTALLSITEARCH)/auto/$(FULLEXT)/.packlist \
+ $(INST_LIB) $(DESTINSTALLSITELIB) \
+ $(INST_ARCHLIB) $(DESTINSTALLSITEARCH) \
+ $(INST_BIN) $(DESTINSTALLSITEBIN) \
+ $(INST_SCRIPT) $(DESTINSTALLSCRIPT) \
+ $(INST_MAN1DIR) $(DESTINSTALLSITEMAN1DIR) \
+ $(INST_MAN3DIR) $(DESTINSTALLSITEMAN3DIR)
+ $(NOECHO) $(WARN_IF_OLD_PACKLIST) \
+ $(PERL_ARCHLIB)/auto/$(FULLEXT)
+
+pure_vendor_install ::
+ $(NOECHO) $(MOD_INSTALL) \
+ read $(VENDORARCHEXP)/auto/$(FULLEXT)/.packlist \
+ write $(DESTINSTALLVENDORARCH)/auto/$(FULLEXT)/.packlist \
+ $(INST_LIB) $(DESTINSTALLVENDORLIB) \
+ $(INST_ARCHLIB) $(DESTINSTALLVENDORARCH) \
+ $(INST_BIN) $(DESTINSTALLVENDORBIN) \
+ $(INST_SCRIPT) $(DESTINSTALLSCRIPT) \
+ $(INST_MAN1DIR) $(DESTINSTALLVENDORMAN1DIR) \
+ $(INST_MAN3DIR) $(DESTINSTALLVENDORMAN3DIR)
+
+doc_perl_install ::
+ $(NOECHO) $(ECHO) Appending installation info to $(DESTINSTALLARCHLIB)/perllocal.pod
+ -$(NOECHO) $(MKPATH) $(DESTINSTALLARCHLIB)
+ -$(NOECHO) $(DOC_INSTALL) \
+ "Module" "$(NAME)" \
+ "installed into" "$(INSTALLPRIVLIB)" \
+ LINKTYPE "$(LINKTYPE)" \
+ VERSION "$(VERSION)" \
+ EXE_FILES "$(EXE_FILES)" \
+ >> $(DESTINSTALLARCHLIB)/perllocal.pod
+
+doc_site_install ::
+ $(NOECHO) $(ECHO) Appending installation info to $(DESTINSTALLARCHLIB)/perllocal.pod
+ -$(NOECHO) $(MKPATH) $(DESTINSTALLARCHLIB)
+ -$(NOECHO) $(DOC_INSTALL) \
+ "Module" "$(NAME)" \
+ "installed into" "$(INSTALLSITELIB)" \
+ LINKTYPE "$(LINKTYPE)" \
+ VERSION "$(VERSION)" \
+ EXE_FILES "$(EXE_FILES)" \
+ >> $(DESTINSTALLARCHLIB)/perllocal.pod
+
+doc_vendor_install ::
+ $(NOECHO) $(ECHO) Appending installation info to $(DESTINSTALLARCHLIB)/perllocal.pod
+ -$(NOECHO) $(MKPATH) $(DESTINSTALLARCHLIB)
+ -$(NOECHO) $(DOC_INSTALL) \
+ "Module" "$(NAME)" \
+ "installed into" "$(INSTALLVENDORLIB)" \
+ LINKTYPE "$(LINKTYPE)" \
+ VERSION "$(VERSION)" \
+ EXE_FILES "$(EXE_FILES)" \
+ >> $(DESTINSTALLARCHLIB)/perllocal.pod
+
+
+uninstall :: uninstall_from_$(INSTALLDIRS)dirs
+ $(NOECHO) $(NOOP)
+
+uninstall_from_perldirs ::
+ $(NOECHO) $(UNINSTALL) $(PERL_ARCHLIB)/auto/$(FULLEXT)/.packlist
+
+uninstall_from_sitedirs ::
+ $(NOECHO) $(UNINSTALL) $(SITEARCHEXP)/auto/$(FULLEXT)/.packlist
+
+uninstall_from_vendordirs ::
+ $(NOECHO) $(UNINSTALL) $(VENDORARCHEXP)/auto/$(FULLEXT)/.packlist
+
+
+# --- MakeMaker force section:
+# Phony target to force checking subdirectories.
+FORCE:
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker perldepend section:
+
+
+# --- MakeMaker makefile section:
+# We take a very conservative approach here, but it's worth it.
+# We move Makefile to Makefile.old here to avoid gnu make looping.
+$(FIRST_MAKEFILE) : Makefile.PL $(CONFIGDEP)
+ $(NOECHO) $(ECHO) "Makefile out-of-date with respect to $?"
+ $(NOECHO) $(ECHO) "Cleaning current config before rebuilding Makefile..."
+ -$(NOECHO) $(RM_F) $(MAKEFILE_OLD)
+ -$(NOECHO) $(MV) $(FIRST_MAKEFILE) $(MAKEFILE_OLD)
+ - $(MAKE) $(USEMAKEFILE) $(MAKEFILE_OLD) clean $(DEV_NULL)
+ $(PERLRUN) Makefile.PL
+ $(NOECHO) $(ECHO) "==> Your Makefile has been rebuilt. <=="
+ $(NOECHO) $(ECHO) "==> Please rerun the $(MAKE) command. <=="
+ false
+
+
+
+# --- MakeMaker staticmake section:
+
+# --- MakeMaker makeaperl section ---
+MAP_TARGET = perl
+FULLPERL = /usr/local/bin/perl
+
+$(MAP_TARGET) :: static $(MAKE_APERL_FILE)
+ $(MAKE) $(USEMAKEFILE) $(MAKE_APERL_FILE) $@
+
+$(MAKE_APERL_FILE) : $(FIRST_MAKEFILE) pm_to_blib
+ $(NOECHO) $(ECHO) Writing \"$(MAKE_APERL_FILE)\" for this $(MAP_TARGET)
+ $(NOECHO) $(PERLRUNINST) \
+ Makefile.PL DIR= \
+ MAKEFILE=$(MAKE_APERL_FILE) LINKTYPE=static \
+ MAKEAPERL=1 NORECURS=1 CCCDLFLAGS=
+
+
+# --- MakeMaker test section:
+
+TEST_VERBOSE=0
+TEST_TYPE=test_$(LINKTYPE)
+TEST_FILE = test.pl
+TEST_FILES = t/*.t
+TESTDB_SW = -d
+
+testdb :: testdb_$(LINKTYPE)
+
+test :: $(TEST_TYPE)
+
+test_dynamic :: pure_all
+ PERL_DL_NONLAZY=1 $(FULLPERLRUN) "-MExtUtils::Command::MM" "-e" "test_harness($(TEST_VERBOSE), '$(INST_LIB)', '$(INST_ARCHLIB)')" $(TEST_FILES)
+
+testdb_dynamic :: pure_all
+ PERL_DL_NONLAZY=1 $(FULLPERLRUN) $(TESTDB_SW) "-I$(INST_LIB)" "-I$(INST_ARCHLIB)" $(TEST_FILE)
+
+test_ : test_dynamic
+
+test_static :: test_dynamic
+testdb_static :: testdb_dynamic
+
+
+# --- MakeMaker ppd section:
+# Creates a PPD (Perl Package Description) for a binary distribution.
+ppd:
+ $(NOECHO) $(ECHO) '<SOFTPKG NAME="$(DISTNAME)" VERSION="1,24,0,0">' > $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <TITLE>$(DISTNAME)</TITLE>' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <ABSTRACT>A grep-like program specifically for large source trees</ABSTRACT>' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <AUTHOR>Andy Lester &lt;andy@petdance.com&gt;</AUTHOR>' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <IMPLEMENTATION>' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <DEPENDENCY NAME="Getopt-Long" VERSION="0,0,0,0" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <DEPENDENCY NAME="Term-ANSIColor" VERSION="0,0,0,0" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <DEPENDENCY NAME="Test-More" VERSION="0,0,0,0" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <OS NAME="$(OSNAME)" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <ARCHITECTURE NAME="darwin-thread-multi-2level" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <CODEBASE HREF="" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' </IMPLEMENTATION>' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) '</SOFTPKG>' >> $(DISTNAME).ppd
+
+
+# --- MakeMaker pm_to_blib section:
+
+pm_to_blib : $(TO_INST_PM)
+ $(NOECHO) $(ABSPERLRUN) -MExtUtils::Install -e 'pm_to_blib({@ARGV}, '\''$(INST_LIB)/auto'\'', '\''$(PM_FILTER)'\'')' -- \
+ Ack.pm $(INST_LIBDIR)/App/Ack.pm
+ $(NOECHO) $(TOUCH) pm_to_blib
+
+
+# --- MakeMaker selfdocument section:
+
+
+# --- MakeMaker postamble section:
+.PHONY: tags
+
+tags:
+ ctags -f tags --recurse --totals \
+ --exclude=blib --exclude=t/lib \
+ --exclude=.svn --exclude='*~' \
+ --languages=Perl --langmap=Perl:+.t \
+
+
+# End.
34 Makefile.PL
@@ -0,0 +1,34 @@
+package main;
+use 5.6.1;
+use strict;
+use warnings;
+use ExtUtils::MakeMaker;
+
+WriteMakefile(
+ NAME => 'ack',
+ AUTHOR => 'Andy Lester <andy@petdance.com>',
+ ABSTRACT => 'A grep-like program specifically for large source trees',
+ VERSION_FROM => 'Ack.pm',
+ PM => { "Ack.pm" => '$(INST_LIBDIR)/App/Ack.pm' },
+ MAN3PODS => {}, # App::Ack's docs aren't useful
+ EXE_FILES => [ 'ack' ],
+ PREREQ_PM => {
+ 'Term::ANSIColor' => 0,
+ 'Getopt::Long' => 0,
+ 'Test::More' => 0,
+ },
+ dist => { COMPRESS => 'gzip -9f', SUFFIX => 'gz', },
+ clean => { FILES => 'ack-*' },
+);
+
+sub MY::postamble {
+ return <<'MAKE_FRAG';
+.PHONY: tags
+
+tags:
+ ctags -f tags --recurse --totals \
+ --exclude=blib --exclude=t/lib \
+ --exclude=.svn --exclude='*~' \
+ --languages=Perl --langmap=Perl:+.t \
+MAKE_FRAG
+}
829 Makefile.old
@@ -0,0 +1,829 @@
+# This Makefile is for the ack extension to perl.
+#
+# It was generated automatically by MakeMaker version
+# 6.30_01 (Revision: 1) from the contents of
+# Makefile.PL. Don't edit this file, edit Makefile.PL instead.
+#
+# ANY CHANGES MADE HERE WILL BE LOST!
+#
+# MakeMaker ARGV: ()
+#
+# MakeMaker Parameters:
+
+# ABSTRACT => q[A grep-like program specifically for large source trees]
+# AUTHOR => q[Andy Lester <andy@petdance.com>]
+# EXE_FILES => [q[ack]]
+# MAN3PODS => { Ack.pm=>q[$(INST_MAN3DIR)/Ack.$(MAN3EXT)] }
+# NAME => q[ack]
+# PM => { Ack.pm=>q[$(INST_LIBDIR)/App/Ack.pm] }
+# PREREQ_PM => { Test::More=>q[0], Getopt::Long=>q[0], Term::ANSIColor=>q[0] }
+# VERSION_FROM => q[Ack.pm]
+# clean => { FILES=>q[ack-*] }
+# dist => { COMPRESS=>q[gzip -9f], SUFFIX=>q[gz] }
+
+# --- MakeMaker post_initialize section:
+
+
+# --- MakeMaker const_config section:
+
+# These definitions are from config.sh (via /System/Library/Perl/5.8.6/darwin-thread-multi-2level/Config.pm)
+
+# They may have been overridden via Makefile.PL or on the command line
+AR = ar
+CC = cc
+CCCDLFLAGS =
+CCDLFLAGS =
+DLEXT = bundle
+DLSRC = dl_dlopen.xs
+EXE_EXT =
+FULL_AR = /usr/bin/ar
+LD = env MACOSX_DEPLOYMENT_TARGET=10.3 cc
+LDDLFLAGS = -bundle -undefined dynamic_lookup -L/usr/local/lib
+LDFLAGS = -L/usr/local/lib
+LIBC = /usr/lib/libc.dylib
+LIB_EXT = .a
+OBJ_EXT = .o
+OSNAME = darwin
+OSVERS = 8.0
+RANLIB = /usr/bin/ar ts
+SITELIBEXP = /Library/Perl/5.8.6
+SITEARCHEXP = /Library/Perl/5.8.6/darwin-thread-multi-2level
+SO = dylib
+VENDORARCHEXP = /Network/Library/Perl/5.8.6/darwin-thread-multi-2level
+VENDORLIBEXP = /Network/Library/Perl/5.8.6
+
+
+# --- MakeMaker constants section:
+AR_STATIC_ARGS = cr
+DIRFILESEP = /
+DFSEP = $(DIRFILESEP)
+NAME = ack
+NAME_SYM = ack
+VERSION = 1.24
+VERSION_MACRO = VERSION
+VERSION_SYM = 1_24
+DEFINE_VERSION = -D$(VERSION_MACRO)=\"$(VERSION)\"
+XS_VERSION = 1.24
+XS_VERSION_MACRO = XS_VERSION
+XS_DEFINE_VERSION = -D$(XS_VERSION_MACRO)=\"$(XS_VERSION)\"
+INST_ARCHLIB = blib/arch
+INST_SCRIPT = blib/script
+INST_BIN = blib/bin
+INST_LIB = blib/lib
+INST_MAN1DIR = blib/man1
+INST_MAN3DIR = blib/man3
+MAN1EXT = 1
+MAN3EXT = 3pm
+INSTALLDIRS = site
+DESTDIR =
+PREFIX = $(SITEPREFIX)
+PERLPREFIX = /
+SITEPREFIX = /usr/local
+VENDORPREFIX = /usr/local
+INSTALLPRIVLIB = /System/Library/Perl/5.8.6
+DESTINSTALLPRIVLIB = $(DESTDIR)$(INSTALLPRIVLIB)
+INSTALLSITELIB = /Library/Perl/5.8.6
+DESTINSTALLSITELIB = $(DESTDIR)$(INSTALLSITELIB)
+INSTALLVENDORLIB = /Network/Library/Perl/5.8.6
+DESTINSTALLVENDORLIB = $(DESTDIR)$(INSTALLVENDORLIB)
+INSTALLARCHLIB = /System/Library/Perl/5.8.6/darwin-thread-multi-2level
+DESTINSTALLARCHLIB = $(DESTDIR)$(INSTALLARCHLIB)
+INSTALLSITEARCH = /Library/Perl/5.8.6/darwin-thread-multi-2level
+DESTINSTALLSITEARCH = $(DESTDIR)$(INSTALLSITEARCH)
+INSTALLVENDORARCH = /Network/Library/Perl/5.8.6/darwin-thread-multi-2level
+DESTINSTALLVENDORARCH = $(DESTDIR)$(INSTALLVENDORARCH)
+INSTALLBIN = /usr/bin
+DESTINSTALLBIN = $(DESTDIR)$(INSTALLBIN)
+INSTALLSITEBIN = /usr/local/bin
+DESTINSTALLSITEBIN = $(DESTDIR)$(INSTALLSITEBIN)
+INSTALLVENDORBIN = /usr/local/bin
+DESTINSTALLVENDORBIN = $(DESTDIR)$(INSTALLVENDORBIN)
+INSTALLSCRIPT = /usr/bin
+DESTINSTALLSCRIPT = $(DESTDIR)$(INSTALLSCRIPT)
+INSTALLMAN1DIR = /usr/share/man/man1
+DESTINSTALLMAN1DIR = $(DESTDIR)$(INSTALLMAN1DIR)
+INSTALLSITEMAN1DIR = /usr/local/man/man1
+DESTINSTALLSITEMAN1DIR = $(DESTDIR)$(INSTALLSITEMAN1DIR)
+INSTALLVENDORMAN1DIR = /usr/local/man/man1
+DESTINSTALLVENDORMAN1DIR = $(DESTDIR)$(INSTALLVENDORMAN1DIR)
+INSTALLMAN3DIR = /usr/share/man/man3
+DESTINSTALLMAN3DIR = $(DESTDIR)$(INSTALLMAN3DIR)
+INSTALLSITEMAN3DIR = /usr/local/man/man3
+DESTINSTALLSITEMAN3DIR = $(DESTDIR)$(INSTALLSITEMAN3DIR)
+INSTALLVENDORMAN3DIR = /usr/local/man/man3
+DESTINSTALLVENDORMAN3DIR = $(DESTDIR)$(INSTALLVENDORMAN3DIR)
+PERL_LIB = /System/Library/Perl/5.8.6
+PERL_ARCHLIB = /System/Library/Perl/5.8.6/darwin-thread-multi-2level
+LIBPERL_A = libperl.a
+FIRST_MAKEFILE = Makefile
+MAKEFILE_OLD = Makefile.old
+MAKE_APERL_FILE = Makefile.aperl
+PERLMAINCC = $(CC)
+PERL_INC = /System/Library/Perl/5.8.6/darwin-thread-multi-2level/CORE
+PERL = /usr/local/bin/perl
+FULLPERL = /usr/local/bin/perl
+ABSPERL = $(PERL)
+PERLRUN = $(PERL)
+FULLPERLRUN = $(FULLPERL)
+ABSPERLRUN = $(ABSPERL)
+PERLRUNINST = $(PERLRUN) "-I$(INST_ARCHLIB)" "-I$(INST_LIB)"
+FULLPERLRUNINST = $(FULLPERLRUN) "-I$(INST_ARCHLIB)" "-I$(INST_LIB)"
+ABSPERLRUNINST = $(ABSPERLRUN) "-I$(INST_ARCHLIB)" "-I$(INST_LIB)"
+PERL_CORE = 0
+PERM_RW = 644
+PERM_RWX = 755
+
+MAKEMAKER = /System/Library/Perl/5.8.6/ExtUtils/MakeMaker.pm
+MM_VERSION = 6.30_01
+MM_REVISION = 1
+
+# FULLEXT = Pathname for extension directory (eg Foo/Bar/Oracle).
+# BASEEXT = Basename part of FULLEXT. May be just equal FULLEXT. (eg Oracle)
+# PARENT_NAME = NAME without BASEEXT and no trailing :: (eg Foo::Bar)
+# DLBASE = Basename part of dynamic library. May be just equal BASEEXT.
+MAKE = make
+FULLEXT = ack
+BASEEXT = ack
+PARENT_NAME =
+DLBASE = $(BASEEXT)
+VERSION_FROM = Ack.pm
+OBJECT =
+LDFROM = $(OBJECT)
+LINKTYPE = dynamic
+BOOTDEP =
+
+# Handy lists of source code files:
+XS_FILES =
+C_FILES =
+O_FILES =
+H_FILES =
+MAN1PODS = ack
+MAN3PODS = Ack.pm
+
+# Where is the Config information that we are using/depend on
+CONFIGDEP = $(PERL_ARCHLIB)$(DFSEP)Config.pm $(PERL_INC)$(DFSEP)config.h
+
+# Where to build things
+INST_LIBDIR = $(INST_LIB)
+INST_ARCHLIBDIR = $(INST_ARCHLIB)
+
+INST_AUTODIR = $(INST_LIB)/auto/$(FULLEXT)
+INST_ARCHAUTODIR = $(INST_ARCHLIB)/auto/$(FULLEXT)
+
+INST_STATIC =
+INST_DYNAMIC =
+INST_BOOT =
+
+# Extra linker info
+EXPORT_LIST =
+PERL_ARCHIVE =
+PERL_ARCHIVE_AFTER =
+
+
+TO_INST_PM = Ack.pm
+
+PM_TO_BLIB = Ack.pm \
+ $(INST_LIBDIR)/App/Ack.pm
+
+
+# --- MakeMaker platform_constants section:
+MM_Unix_VERSION = 1.50_01
+PERL_MALLOC_DEF = -DPERL_EXTMALLOC_DEF -Dmalloc=Perl_malloc -Dfree=Perl_mfree -Drealloc=Perl_realloc -Dcalloc=Perl_calloc
+
+
+# --- MakeMaker tool_autosplit section:
+# Usage: $(AUTOSPLITFILE) FileToSplit AutoDirToSplitInto
+AUTOSPLITFILE = $(ABSPERLRUN) -e 'use AutoSplit; autosplit($$ARGV[0], $$ARGV[1], 0, 1, 1)' --
+
+
+
+# --- MakeMaker tool_xsubpp section:
+
+
+# --- MakeMaker tools_other section:
+SHELL = /bin/sh
+CHMOD = chmod
+CP = cp
+MV = mv
+NOOP = $(SHELL) -c true
+NOECHO = @
+RM_F = rm -f
+RM_RF = rm -rf
+TEST_F = test -f
+TOUCH = touch
+UMASK_NULL = umask 0
+DEV_NULL = > /dev/null 2>&1
+MKPATH = $(ABSPERLRUN) "-MExtUtils::Command" -e mkpath
+EQUALIZE_TIMESTAMP = $(ABSPERLRUN) "-MExtUtils::Command" -e eqtime
+ECHO = echo
+ECHO_N = echo -n
+UNINST = 0
+VERBINST = 0
+MOD_INSTALL = $(ABSPERLRUN) -MExtUtils::Install -e 'install({@ARGV}, '\''$(VERBINST)'\'', 0, '\''$(UNINST)'\'');' --
+DOC_INSTALL = $(ABSPERLRUN) "-MExtUtils::Command::MM" -e perllocal_install
+UNINSTALL = $(ABSPERLRUN) "-MExtUtils::Command::MM" -e uninstall
+WARN_IF_OLD_PACKLIST = $(ABSPERLRUN) "-MExtUtils::Command::MM" -e warn_if_old_packlist
+MACROSTART =
+MACROEND =
+USEMAKEFILE = -f
+FIXIN = $(PERLRUN) "-MExtUtils::MY" -e "MY->fixin(shift)"
+
+
+# --- MakeMaker makemakerdflt section:
+makemakerdflt: all
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker dist section:
+TAR = tar
+TARFLAGS = cvf
+ZIP = zip
+ZIPFLAGS = -r
+COMPRESS = gzip -9f
+SUFFIX = gz
+SHAR = shar
+PREOP = $(NOECHO) $(NOOP)
+POSTOP = $(NOECHO) $(NOOP)
+TO_UNIX = $(NOECHO) $(NOOP)
+CI = ci -u
+RCS_LABEL = rcs -Nv$(VERSION_SYM): -q
+DIST_CP = best
+DIST_DEFAULT = tardist
+DISTNAME = ack
+DISTVNAME = ack-1.24
+
+
+# --- MakeMaker macro section:
+
+
+# --- MakeMaker depend section:
+
+
+# --- MakeMaker cflags section:
+
+
+# --- MakeMaker const_loadlibs section:
+
+
+# --- MakeMaker const_cccmd section:
+
+
+# --- MakeMaker post_constants section:
+
+
+# --- MakeMaker pasthru section:
+
+PASTHRU = LIBPERL_A="$(LIBPERL_A)"\
+ LINKTYPE="$(LINKTYPE)"\
+ PREFIX="$(PREFIX)"
+
+
+# --- MakeMaker special_targets section:
+.SUFFIXES : .xs .c .C .cpp .i .s .cxx .cc $(OBJ_EXT)
+
+.PHONY: all config static dynamic test linkext manifest blibdirs clean realclean disttest distdir
+
+
+
+# --- MakeMaker c_o section:
+
+
+# --- MakeMaker xs_c section:
+
+
+# --- MakeMaker xs_o section:
+
+
+# --- MakeMaker top_targets section:
+all :: pure_all manifypods
+ $(NOECHO) $(NOOP)
+
+
+pure_all :: config pm_to_blib subdirs linkext
+ $(NOECHO) $(NOOP)
+
+subdirs :: $(MYEXTLIB)
+ $(NOECHO) $(NOOP)
+
+config :: $(FIRST_MAKEFILE) blibdirs
+ $(NOECHO) $(NOOP)
+
+help :
+ perldoc ExtUtils::MakeMaker
+
+
+# --- MakeMaker blibdirs section:
+blibdirs : $(INST_LIBDIR)$(DFSEP).exists $(INST_ARCHLIB)$(DFSEP).exists $(INST_AUTODIR)$(DFSEP).exists $(INST_ARCHAUTODIR)$(DFSEP).exists $(INST_BIN)$(DFSEP).exists $(INST_SCRIPT)$(DFSEP).exists $(INST_MAN1DIR)$(DFSEP).exists $(INST_MAN3DIR)$(DFSEP).exists
+ $(NOECHO) $(NOOP)
+
+# Backwards compat with 6.18 through 6.25
+blibdirs.ts : blibdirs
+ $(NOECHO) $(NOOP)
+
+$(INST_LIBDIR)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_LIBDIR)
+ $(NOECHO) $(CHMOD) 755 $(INST_LIBDIR)
+ $(NOECHO) $(TOUCH) $(INST_LIBDIR)$(DFSEP).exists
+
+$(INST_ARCHLIB)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_ARCHLIB)
+ $(NOECHO) $(CHMOD) 755 $(INST_ARCHLIB)
+ $(NOECHO) $(TOUCH) $(INST_ARCHLIB)$(DFSEP).exists
+
+$(INST_AUTODIR)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_AUTODIR)
+ $(NOECHO) $(CHMOD) 755 $(INST_AUTODIR)
+ $(NOECHO) $(TOUCH) $(INST_AUTODIR)$(DFSEP).exists
+
+$(INST_ARCHAUTODIR)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_ARCHAUTODIR)
+ $(NOECHO) $(CHMOD) 755 $(INST_ARCHAUTODIR)
+ $(NOECHO) $(TOUCH) $(INST_ARCHAUTODIR)$(DFSEP).exists
+
+$(INST_BIN)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_BIN)
+ $(NOECHO) $(CHMOD) 755 $(INST_BIN)
+ $(NOECHO) $(TOUCH) $(INST_BIN)$(DFSEP).exists
+
+$(INST_SCRIPT)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_SCRIPT)
+ $(NOECHO) $(CHMOD) 755 $(INST_SCRIPT)
+ $(NOECHO) $(TOUCH) $(INST_SCRIPT)$(DFSEP).exists
+
+$(INST_MAN1DIR)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_MAN1DIR)
+ $(NOECHO) $(CHMOD) 755 $(INST_MAN1DIR)
+ $(NOECHO) $(TOUCH) $(INST_MAN1DIR)$(DFSEP).exists
+
+$(INST_MAN3DIR)$(DFSEP).exists :: Makefile.PL
+ $(NOECHO) $(MKPATH) $(INST_MAN3DIR)
+ $(NOECHO) $(CHMOD) 755 $(INST_MAN3DIR)
+ $(NOECHO) $(TOUCH) $(INST_MAN3DIR)$(DFSEP).exists
+
+
+
+# --- MakeMaker linkext section:
+
+linkext :: $(LINKTYPE)
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker dlsyms section:
+
+
+# --- MakeMaker dynamic section:
+
+dynamic :: $(FIRST_MAKEFILE) $(INST_DYNAMIC) $(INST_BOOT)
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker dynamic_bs section:
+
+BOOTSTRAP =
+
+
+# --- MakeMaker dynamic_lib section:
+
+
+# --- MakeMaker static section:
+
+## $(INST_PM) has been moved to the all: target.
+## It remains here for awhile to allow for old usage: "make static"
+static :: $(FIRST_MAKEFILE) $(INST_STATIC)
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker static_lib section:
+
+
+# --- MakeMaker manifypods section:
+
+POD2MAN_EXE = $(PERLRUN) "-MExtUtils::Command::MM" -e pod2man "--"
+POD2MAN = $(POD2MAN_EXE)
+
+
+manifypods : pure_all \
+ ack \
+ Ack.pm \
+ Ack.pm
+ $(NOECHO) $(POD2MAN) --section=1 --perm_rw=$(PERM_RW) \
+ ack $(INST_MAN1DIR)/ack.$(MAN1EXT)
+ $(NOECHO) $(POD2MAN) --section=3 --perm_rw=$(PERM_RW) \
+ Ack.pm $(INST_MAN3DIR)/Ack.$(MAN3EXT)
+
+
+
+
+# --- MakeMaker processPL section:
+
+
+# --- MakeMaker installbin section:
+
+EXE_FILES = ack
+
+pure_all :: $(INST_SCRIPT)/ack
+ $(NOECHO) $(NOOP)
+
+realclean ::
+ $(RM_F) \
+ $(INST_SCRIPT)/ack
+
+$(INST_SCRIPT)/ack : ack $(FIRST_MAKEFILE) $(INST_SCRIPT)$(DFSEP).exists $(INST_BIN)$(DFSEP).exists
+ $(NOECHO) $(RM_F) $(INST_SCRIPT)/ack
+ $(CP) ack $(INST_SCRIPT)/ack
+ $(FIXIN) $(INST_SCRIPT)/ack
+ -$(NOECHO) $(CHMOD) $(PERM_RWX) $(INST_SCRIPT)/ack
+
+
+
+# --- MakeMaker subdirs section:
+
+# none
+
+# --- MakeMaker clean_subdirs section:
+clean_subdirs :
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker clean section:
+
+# Delete temporary files but do not touch installed files. We don't delete
+# the Makefile here so a later make realclean still has a makefile to use.
+
+clean :: clean_subdirs
+ - $(RM_F) \
+ *$(LIB_EXT) core \
+ core.[0-9] $(INST_ARCHAUTODIR)/extralibs.all \
+ core.[0-9][0-9] $(BASEEXT).bso \
+ pm_to_blib.ts core.[0-9][0-9][0-9][0-9] \
+ $(BASEEXT).x $(BOOTSTRAP) \
+ perl$(EXE_EXT) tmon.out \
+ *$(OBJ_EXT) pm_to_blib \
+ $(INST_ARCHAUTODIR)/extralibs.ld blibdirs.ts \
+ core.[0-9][0-9][0-9][0-9][0-9] *perl.core \
+ core.*perl.*.? $(MAKE_APERL_FILE) \
+ perl $(BASEEXT).def \
+ core.[0-9][0-9][0-9] mon.out \
+ lib$(BASEEXT).def perlmain.c \
+ perl.exe so_locations \
+ $(BASEEXT).exp
+ - $(RM_RF) \
+ ack-* blib
+ - $(MV) $(FIRST_MAKEFILE) $(MAKEFILE_OLD) $(DEV_NULL)
+
+
+# --- MakeMaker realclean_subdirs section:
+realclean_subdirs :
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker realclean section:
+# Delete temporary files (via clean) and also delete dist files
+realclean purge :: clean realclean_subdirs
+ - $(RM_F) \
+ $(MAKEFILE_OLD) $(FIRST_MAKEFILE)
+ - $(RM_RF) \
+ $(DISTVNAME)
+
+
+# --- MakeMaker metafile section:
+metafile : create_distdir
+ $(NOECHO) $(ECHO) Generating META.yml
+ $(NOECHO) $(ECHO) '--- #YAML:1.0' > META_new.yml
+ $(NOECHO) $(ECHO) 'name: ack' >> META_new.yml
+ $(NOECHO) $(ECHO) 'version: 1.24' >> META_new.yml
+ $(NOECHO) $(ECHO) 'abstract: A grep-like program specifically for large source trees' >> META_new.yml
+ $(NOECHO) $(ECHO) 'license: unknown' >> META_new.yml
+ $(NOECHO) $(ECHO) 'generated_by: ExtUtils::MakeMaker version 6.30_01' >> META_new.yml
+ $(NOECHO) $(ECHO) 'author: Andy Lester <andy@petdance.com>' >> META_new.yml
+ $(NOECHO) $(ECHO) 'distribution_type: module' >> META_new.yml
+ $(NOECHO) $(ECHO) 'requires: ' >> META_new.yml
+ $(NOECHO) $(ECHO) ' Getopt::Long: 0' >> META_new.yml
+ $(NOECHO) $(ECHO) ' Term::ANSIColor: 0' >> META_new.yml
+ $(NOECHO) $(ECHO) ' Test::More: 0' >> META_new.yml
+ $(NOECHO) $(ECHO) 'meta-spec:' >> META_new.yml
+ $(NOECHO) $(ECHO) ' url: <http://module-build.sourceforge.net/META-spec-new.html>;' >> META_new.yml
+ $(NOECHO) $(ECHO) ' version: 1.1' >> META_new.yml
+ -$(NOECHO) $(MV) META_new.yml $(DISTVNAME)/META.yml
+
+
+# --- MakeMaker signature section:
+signature :
+ cpansign -s
+
+
+# --- MakeMaker dist_basics section:
+distclean :: realclean distcheck
+ $(NOECHO) $(NOOP)
+
+distcheck :
+ $(PERLRUN) "-MExtUtils::Manifest=fullcheck" -e fullcheck
+
+skipcheck :
+ $(PERLRUN) "-MExtUtils::Manifest=skipcheck" -e skipcheck
+
+manifest :
+ $(PERLRUN) "-MExtUtils::Manifest=mkmanifest" -e mkmanifest
+
+veryclean : realclean
+ $(RM_F) *~ *.orig */*~ */*.orig
+
+
+
+# --- MakeMaker dist_core section:
+
+dist : $(DIST_DEFAULT) $(FIRST_MAKEFILE)
+ $(NOECHO) $(ABSPERLRUN) -l -e 'print '\''Warning: Makefile possibly out of date with $(VERSION_FROM)'\''' \
+ -e ' if -e '\''$(VERSION_FROM)'\'' and -M '\''$(VERSION_FROM)'\'' < -M '\''$(FIRST_MAKEFILE)'\'';' --
+
+tardist : $(DISTVNAME).tar$(SUFFIX)
+ $(NOECHO) $(NOOP)
+
+uutardist : $(DISTVNAME).tar$(SUFFIX)
+ uuencode $(DISTVNAME).tar$(SUFFIX) $(DISTVNAME).tar$(SUFFIX) > $(DISTVNAME).tar$(SUFFIX)_uu
+
+$(DISTVNAME).tar$(SUFFIX) : distdir
+ $(PREOP)
+ $(TO_UNIX)
+ $(TAR) $(TARFLAGS) $(DISTVNAME).tar $(DISTVNAME)
+ $(RM_RF) $(DISTVNAME)
+ $(COMPRESS) $(DISTVNAME).tar
+ $(POSTOP)
+
+zipdist : $(DISTVNAME).zip
+ $(NOECHO) $(NOOP)
+
+$(DISTVNAME).zip : distdir
+ $(PREOP)
+ $(ZIP) $(ZIPFLAGS) $(DISTVNAME).zip $(DISTVNAME)
+ $(RM_RF) $(DISTVNAME)
+ $(POSTOP)
+
+shdist : distdir
+ $(PREOP)
+ $(SHAR) $(DISTVNAME) > $(DISTVNAME).shar
+ $(RM_RF) $(DISTVNAME)
+ $(POSTOP)
+
+
+# --- MakeMaker distdir section:
+create_distdir :
+ $(RM_RF) $(DISTVNAME)
+ $(PERLRUN) "-MExtUtils::Manifest=manicopy,maniread" \
+ -e "manicopy(maniread(),'$(DISTVNAME)', '$(DIST_CP)');"
+
+distdir : create_distdir distmeta
+ $(NOECHO) $(NOOP)
+
+
+
+# --- MakeMaker dist_test section:
+disttest : distdir
+ cd $(DISTVNAME) && $(ABSPERLRUN) Makefile.PL
+ cd $(DISTVNAME) && $(MAKE) $(PASTHRU)
+ cd $(DISTVNAME) && $(MAKE) test $(PASTHRU)
+
+
+
+# --- MakeMaker dist_ci section:
+
+ci :
+ $(PERLRUN) "-MExtUtils::Manifest=maniread" \
+ -e "@all = keys %{ maniread() };" \
+ -e "print(qq{Executing $(CI) @all\n}); system(qq{$(CI) @all});" \
+ -e "print(qq{Executing $(RCS_LABEL) ...\n}); system(qq{$(RCS_LABEL) @all});"
+
+
+# --- MakeMaker distmeta section:
+distmeta : create_distdir metafile
+ $(NOECHO) cd $(DISTVNAME) && $(ABSPERLRUN) -MExtUtils::Manifest=maniadd -e 'eval { maniadd({q{META.yml} => q{Module meta-data (added by MakeMaker)}}) } ' \
+ -e ' or print "Could not add META.yml to MANIFEST: $${'\''@'\''}\n"' --
+
+
+
+# --- MakeMaker distsignature section:
+distsignature : create_distdir
+ $(NOECHO) cd $(DISTVNAME) && $(ABSPERLRUN) -MExtUtils::Manifest=maniadd -e 'eval { maniadd({q{SIGNATURE} => q{Public-key signature (added by MakeMaker)}}) } ' \
+ -e ' or print "Could not add SIGNATURE to MANIFEST: $${'\''@'\''}\n"' --
+ $(NOECHO) cd $(DISTVNAME) && $(TOUCH) SIGNATURE
+ cd $(DISTVNAME) && cpansign -s
+
+
+
+# --- MakeMaker install section:
+
+install :: all pure_install doc_install
+ $(NOECHO) $(NOOP)
+
+install_perl :: all pure_perl_install doc_perl_install
+ $(NOECHO) $(NOOP)
+
+install_site :: all pure_site_install doc_site_install
+ $(NOECHO) $(NOOP)
+
+install_vendor :: all pure_vendor_install doc_vendor_install
+ $(NOECHO) $(NOOP)
+
+pure_install :: pure_$(INSTALLDIRS)_install
+ $(NOECHO) $(NOOP)
+
+doc_install :: doc_$(INSTALLDIRS)_install
+ $(NOECHO) $(NOOP)
+
+pure__install : pure_site_install
+ $(NOECHO) $(ECHO) INSTALLDIRS not defined, defaulting to INSTALLDIRS=site
+
+doc__install : doc_site_install
+ $(NOECHO) $(ECHO) INSTALLDIRS not defined, defaulting to INSTALLDIRS=site
+
+pure_perl_install ::
+ $(NOECHO) $(MOD_INSTALL) \
+ read $(PERL_ARCHLIB)/auto/$(FULLEXT)/.packlist \
+ write $(DESTINSTALLARCHLIB)/auto/$(FULLEXT)/.packlist \
+ $(INST_LIB) $(DESTINSTALLPRIVLIB) \
+ $(INST_ARCHLIB) $(DESTINSTALLARCHLIB) \
+ $(INST_BIN) $(DESTINSTALLBIN) \
+ $(INST_SCRIPT) $(DESTINSTALLSCRIPT) \
+ $(INST_MAN1DIR) $(DESTINSTALLMAN1DIR) \
+ $(INST_MAN3DIR) $(DESTINSTALLMAN3DIR)
+ $(NOECHO) $(WARN_IF_OLD_PACKLIST) \
+ $(SITEARCHEXP)/auto/$(FULLEXT)
+
+
+pure_site_install ::
+ $(NOECHO) $(MOD_INSTALL) \
+ read $(SITEARCHEXP)/auto/$(FULLEXT)/.packlist \
+ write $(DESTINSTALLSITEARCH)/auto/$(FULLEXT)/.packlist \
+ $(INST_LIB) $(DESTINSTALLSITELIB) \
+ $(INST_ARCHLIB) $(DESTINSTALLSITEARCH) \
+ $(INST_BIN) $(DESTINSTALLSITEBIN) \
+ $(INST_SCRIPT) $(DESTINSTALLSCRIPT) \
+ $(INST_MAN1DIR) $(DESTINSTALLSITEMAN1DIR) \
+ $(INST_MAN3DIR) $(DESTINSTALLSITEMAN3DIR)
+ $(NOECHO) $(WARN_IF_OLD_PACKLIST) \
+ $(PERL_ARCHLIB)/auto/$(FULLEXT)
+
+pure_vendor_install ::
+ $(NOECHO) $(MOD_INSTALL) \
+ read $(VENDORARCHEXP)/auto/$(FULLEXT)/.packlist \
+ write $(DESTINSTALLVENDORARCH)/auto/$(FULLEXT)/.packlist \
+ $(INST_LIB) $(DESTINSTALLVENDORLIB) \
+ $(INST_ARCHLIB) $(DESTINSTALLVENDORARCH) \
+ $(INST_BIN) $(DESTINSTALLVENDORBIN) \
+ $(INST_SCRIPT) $(DESTINSTALLSCRIPT) \
+ $(INST_MAN1DIR) $(DESTINSTALLVENDORMAN1DIR) \
+ $(INST_MAN3DIR) $(DESTINSTALLVENDORMAN3DIR)
+
+doc_perl_install ::
+ $(NOECHO) $(ECHO) Appending installation info to $(DESTINSTALLARCHLIB)/perllocal.pod
+ -$(NOECHO) $(MKPATH) $(DESTINSTALLARCHLIB)
+ -$(NOECHO) $(DOC_INSTALL) \
+ "Module" "$(NAME)" \
+ "installed into" "$(INSTALLPRIVLIB)" \
+ LINKTYPE "$(LINKTYPE)" \
+ VERSION "$(VERSION)" \
+ EXE_FILES "$(EXE_FILES)" \
+ >> $(DESTINSTALLARCHLIB)/perllocal.pod
+
+doc_site_install ::
+ $(NOECHO) $(ECHO) Appending installation info to $(DESTINSTALLARCHLIB)/perllocal.pod
+ -$(NOECHO) $(MKPATH) $(DESTINSTALLARCHLIB)
+ -$(NOECHO) $(DOC_INSTALL) \
+ "Module" "$(NAME)" \
+ "installed into" "$(INSTALLSITELIB)" \
+ LINKTYPE "$(LINKTYPE)" \
+ VERSION "$(VERSION)" \
+ EXE_FILES "$(EXE_FILES)" \
+ >> $(DESTINSTALLARCHLIB)/perllocal.pod
+
+doc_vendor_install ::
+ $(NOECHO) $(ECHO) Appending installation info to $(DESTINSTALLARCHLIB)/perllocal.pod
+ -$(NOECHO) $(MKPATH) $(DESTINSTALLARCHLIB)
+ -$(NOECHO) $(DOC_INSTALL) \
+ "Module" "$(NAME)" \
+ "installed into" "$(INSTALLVENDORLIB)" \
+ LINKTYPE "$(LINKTYPE)" \
+ VERSION "$(VERSION)" \
+ EXE_FILES "$(EXE_FILES)" \
+ >> $(DESTINSTALLARCHLIB)/perllocal.pod
+
+
+uninstall :: uninstall_from_$(INSTALLDIRS)dirs
+ $(NOECHO) $(NOOP)
+
+uninstall_from_perldirs ::
+ $(NOECHO) $(UNINSTALL) $(PERL_ARCHLIB)/auto/$(FULLEXT)/.packlist
+
+uninstall_from_sitedirs ::
+ $(NOECHO) $(UNINSTALL) $(SITEARCHEXP)/auto/$(FULLEXT)/.packlist
+
+uninstall_from_vendordirs ::
+ $(NOECHO) $(UNINSTALL) $(VENDORARCHEXP)/auto/$(FULLEXT)/.packlist
+
+
+# --- MakeMaker force section:
+# Phony target to force checking subdirectories.
+FORCE:
+ $(NOECHO) $(NOOP)
+
+
+# --- MakeMaker perldepend section:
+
+
+# --- MakeMaker makefile section:
+# We take a very conservative approach here, but it's worth it.
+# We move Makefile to Makefile.old here to avoid gnu make looping.
+$(FIRST_MAKEFILE) : Makefile.PL $(CONFIGDEP)
+ $(NOECHO) $(ECHO) "Makefile out-of-date with respect to $?"
+ $(NOECHO) $(ECHO) "Cleaning current config before rebuilding Makefile..."
+ -$(NOECHO) $(RM_F) $(MAKEFILE_OLD)
+ -$(NOECHO) $(MV) $(FIRST_MAKEFILE) $(MAKEFILE_OLD)
+ - $(MAKE) $(USEMAKEFILE) $(MAKEFILE_OLD) clean $(DEV_NULL)
+ $(PERLRUN) Makefile.PL
+ $(NOECHO) $(ECHO) "==> Your Makefile has been rebuilt. <=="
+ $(NOECHO) $(ECHO) "==> Please rerun the $(MAKE) command. <=="
+ false
+
+
+
+# --- MakeMaker staticmake section:
+
+# --- MakeMaker makeaperl section ---
+MAP_TARGET = perl
+FULLPERL = /usr/local/bin/perl
+
+$(MAP_TARGET) :: static $(MAKE_APERL_FILE)
+ $(MAKE) $(USEMAKEFILE) $(MAKE_APERL_FILE) $@
+
+$(MAKE_APERL_FILE) : $(FIRST_MAKEFILE) pm_to_blib
+ $(NOECHO) $(ECHO) Writing \"$(MAKE_APERL_FILE)\" for this $(MAP_TARGET)
+ $(NOECHO) $(PERLRUNINST) \
+ Makefile.PL DIR= \
+ MAKEFILE=$(MAKE_APERL_FILE) LINKTYPE=static \
+ MAKEAPERL=1 NORECURS=1 CCCDLFLAGS=
+
+
+# --- MakeMaker test section:
+
+TEST_VERBOSE=0
+TEST_TYPE=test_$(LINKTYPE)
+TEST_FILE = test.pl
+TEST_FILES = t/*.t
+TESTDB_SW = -d
+
+testdb :: testdb_$(LINKTYPE)
+
+test :: $(TEST_TYPE)
+
+test_dynamic :: pure_all
+ PERL_DL_NONLAZY=1 $(FULLPERLRUN) "-MExtUtils::Command::MM" "-e" "test_harness($(TEST_VERBOSE), '$(INST_LIB)', '$(INST_ARCHLIB)')" $(TEST_FILES)
+
+testdb_dynamic :: pure_all
+ PERL_DL_NONLAZY=1 $(FULLPERLRUN) $(TESTDB_SW) "-I$(INST_LIB)" "-I$(INST_ARCHLIB)" $(TEST_FILE)
+
+test_ : test_dynamic
+
+test_static :: test_dynamic
+testdb_static :: testdb_dynamic
+
+
+# --- MakeMaker ppd section:
+# Creates a PPD (Perl Package Description) for a binary distribution.
+ppd:
+ $(NOECHO) $(ECHO) '<SOFTPKG NAME="$(DISTNAME)" VERSION="1,24,0,0">' > $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <TITLE>$(DISTNAME)</TITLE>' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <ABSTRACT>A grep-like program specifically for large source trees</ABSTRACT>' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <AUTHOR>Andy Lester &lt;andy@petdance.com&gt;</AUTHOR>' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <IMPLEMENTATION>' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <DEPENDENCY NAME="Getopt-Long" VERSION="0,0,0,0" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <DEPENDENCY NAME="Term-ANSIColor" VERSION="0,0,0,0" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <DEPENDENCY NAME="Test-More" VERSION="0,0,0,0" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <OS NAME="$(OSNAME)" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <ARCHITECTURE NAME="darwin-thread-multi-2level" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' <CODEBASE HREF="" />' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) ' </IMPLEMENTATION>' >> $(DISTNAME).ppd
+ $(NOECHO) $(ECHO) '</SOFTPKG>' >> $(DISTNAME).ppd
+
+
+# --- MakeMaker pm_to_blib section:
+
+pm_to_blib : $(TO_INST_PM)
+ $(NOECHO) $(ABSPERLRUN) -MExtUtils::Install -e 'pm_to_blib({@ARGV}, '\''$(INST_LIB)/auto'\'', '\''$(PM_FILTER)'\'')' -- \
+ Ack.pm $(INST_LIBDIR)/App/Ack.pm
+ $(NOECHO) $(TOUCH) pm_to_blib
+
+
+# --- MakeMaker selfdocument section:
+
+
+# --- MakeMaker postamble section:
+.PHONY: tags
+
+tags:
+ ctags -f tags --recurse --totals \
+ --exclude=blib --exclude=t/lib \
+ --exclude=.svn --exclude='*~' \
+ --languages=Perl --langmap=Perl:+.t \
+
+
+# End.
34 README
@@ -0,0 +1,34 @@
+ack is a grep-like tool tailored to working with large trees of source
+code.
+
+INSTALLATION
+
+To install this module, run the following commands:
+
+ perl Makefile.PL
+ make
+ make test
+ make install
+
+SUPPORT AND DOCUMENTATION
+
+You can look for information at:
+
+ Search CPAN
+ http://search.cpan.org/dist/ack
+
+ CPAN Request Tracker:
+ http://rt.cpan.org/NoAuth/Bugs.html?Dist=ack
+
+ AnnoCPAN, annotated CPAN documentation:
+ http://annocpan.org/dist/ack
+
+ CPAN Ratings:
+ http://cpanratings.perl.org/d/ack
+
+COPYRIGHT AND LICENCE
+
+Copyright (C) 2005 Andy Lester
+
+This program is free software; you can redistribute it and/or modify it
+under the same terms as Perl itself.
260 ack
@@ -0,0 +1,260 @@
+#!/usr/local/bin/perl
+
+use warnings;
+use strict;
+
+our $is_windows;
+BEGIN {
+ $is_windows = ($^O =~ /MSWin32/);
+}
+
+BEGIN {
+ eval { use Term::ANSIColor } unless $is_windows;
+}
+
+use App::Ack;
+use Getopt::Long;
+
+our %opt;
+our %lang;
+
+our $is_tty = -t STDOUT;
+$opt{group} = $is_tty;
+$opt{color} = $is_tty && !$is_windows;
+$opt{all} = 0;
+$opt{help} = 0;
+$opt{m} = 0;
+
+my %options = (
+ a => \$opt{all},
+ "all!" => \$opt{all},
+ c => \$opt{count},
+ count => \$opt{count},
+ f => \$opt{f},
+ h => \$opt{h},
+ H => \$opt{H},
+ i => \$opt{i},
+ l => \$opt{l},
+ "m=i" => \$opt{m},
+ n => \$opt{n},
+ o => \$opt{o},
+ v => \$opt{v},
+ w => \$opt{w},
+
+ "group!" => \$opt{group},
+ "color!" => \$opt{color},
+ "help" => \$opt{help},
+ "version" => sub { print "ack $App::Ack::VERSION\n" and exit 1; },
+);
+
+my @filetypes_supported = App::Ack::filetypes_supported();
+for my $i ( @filetypes_supported ) {
+ $options{ "$i!" } = \$lang{ $i };
+}
+$options{ "js!" } = \$lang{ javascript };
+
+# Stick any default switches at the beginning, so they can be overridden
+# by the command line switches.
+unshift @ARGV, split( " ", $ENV{ACK_SWITCHES} ) if defined $ENV{ACK_SWITCHES};
+
+map { App::Ack::_thpppt($_) if /^--th[bp]+t$/ } @ARGV;
+Getopt::Long::Configure( "bundling" );
+GetOptions( %options ) or die "ack --help for options.\n";
+
+my $filetypes_supported_set = grep { defined $lang{$_} && ($lang{$_} == 1) } @filetypes_supported;
+my $filetypes_supported_unset = grep { defined $lang{$_} && ($lang{$_} == 0) } @filetypes_supported;
+
+# If anyone says --noperl, we assume all other languages must be on.
+if ( !$filetypes_supported_set ) {
+ for ( keys %lang ) {
+ $lang{$_} = 1 unless defined $lang{$_};
+ }
+}
+
+if ( $opt{help} || (!@ARGV && !$opt{f}) ) {
+ App::Ack::show_help();
+ exit 1;
+}
+
+my $re;
+
+if ( !$opt{f} ) {
+ $re = shift or die "No regex specified\n";
+
+ if ( $opt{w} ) {
+ $re = $opt{i} ? qr/\b$re\b/i : qr/\b$re\b/;
+ }
+ else {
+ $re = $opt{i} ? qr/$re/i : qr/$re/;
+ }
+}
+
+
+my $is_filter = !-t STDIN;
+my @what;
+if ( @ARGV ) {
+ @what = @ARGV;
+
+ # Show filenames unless we've specified one single file
+ $opt{show_filename} = (@what > 1) || (!-f $what[0]);
+}
+else {
+ if ( $is_filter ) {
+ # We're going into filter mode
+ for ( qw( f l ) ) {
+ $opt{$_} and die "ack: Can't use -$_ when acting as a filter.\n";
+ }
+ $opt{show_filename} = 0;
+ search( "-", $re, %opt );
+ exit 0;
+ }
+ else {
+ @what = ""; # Assume current directory
+ $opt{show_filename} = 1;
+ }
+}
+$opt{show_filename} = 0 if $opt{h};
+$opt{show_filename} = 1 if $opt{H};
+
+my $filter = $opt{all} ? sub {1} : \&is_interesting;
+my $iter = App::Ack::interesting_files( $filter, !$opt{n}, @what );
+
+while ( my $file = $iter->() ) {
+ if ( $opt{f} ) {
+ print "$file\n";
+ }
+ else {
+ search( $file, $re, %opt );
+ }
+}
+exit 0;
+
+sub is_interesting {
+ my $file = shift;
+
+ return if $file =~ /~$/;
+ return if $file =~ /^\./;
+
+ for my $type ( App::Ack::filetypes( $file ) ) {
+ return 1 if $lang{$type};
+ }
+ return;
+}
+
+sub search {
+ my $filename = shift;
+ my $regex = shift;
+ my %opt = @_;
+
+ my $nmatches = 0;
+
+ my $fh;
+ if ( $filename eq "-" ) {
+ $fh = *STDIN;
+ }
+ else {
+ if ( !open( $fh, "<", $filename ) ) {
+ warn "ack: $filename: $!\n";
+ return;
+ }
+ }
+
+ local $_; ## no critic
+ while (<$fh>) {
+ if ( /$re/ ) { # If we have a matching line
+ ++$nmatches;
+ if ( !$opt{count} ) {
+ if ( $nmatches == 1 ) {
+ # No point in searching more if we only want a list
+ last if $opt{l};
+ }
+ next if $opt{v};
+
+ my $out;
+ if ( $opt{o} ) {
+ $out = "$&\n";
+ }
+ else {
+ $out = $_;
+ $out =~ s/($re)/colored($1,"black on_yellow")/eg if $opt{color};
+ }
+
+ if ( $opt{show_filename} ) {
+ my $colorname = $opt{color} ? colored( $filename, "bold green" ) : $filename;
+ if ( $opt{group} ) {
+ print "$colorname\n" if $nmatches == 1;
+ print "$.:$out";
+ }
+ else {
+ print "${colorname}:$.:$out";
+ }
+ }
+ else {
+ print $out;
+ }
+ } # Not just --count
+
+ last if $opt{m} && ( $nmatches >= $opt{m} );
+ } # match
+ else { # no match
+ if ( $opt{v} ) {
+ print "${filename}:" if $opt{show_filename};
+ print $_;
+ }
+ }
+ } # while
+ close $fh;
+
+ if ( $opt{count} ) {
+ print "${filename}:${nmatches}\n";
+ }
+ else {
+ if ( $opt{l} ) {
+ print "$filename\n" if ($opt{v} && !$nmatches) || ($nmatches && !$opt{v});
+ }
+ else {
+ print "\n" if $nmatches && $opt{show_filename} && $opt{group} && !$opt{v};
+ }
+ }
+
+ return;
+}
+
+=head1 NAME
+
+ack - grep-like text finder for large trees of text
+
+=head1 DESCRIPTION
+
+F<ack> is a F<grep>-like program with optimizations for searching through
+large trees of source code.
+
+Key improvements include:
+
+=over 4
+
+=item * Defaults to only searching program source code
+
+=item * Defaults to recursively searching directories
+
+=item * Ignores F<blib> directories.
+
+=item * Ignores source code control directories, like F<CVS>, F<.svn> and F<_darcs>.
+
+=item * Uses Perl regular expressions
+
+=item * Highlights matched text
+
+=back
+
+=head1 TODO
+
+=over 4
+
+=item * Search through standard input if no files specified
+
+=item * Add a --[no]comment option to grep inside or exclude comments.
+
+=back
+
+=cut
11 t/00-load.t
@@ -0,0 +1,11 @@
+#!perl -T
+
+use warnings;
+use strict;
+use Test::More tests => 1;
+
+BEGIN {
+ use_ok( 'App::Ack' );
+}
+
+diag( "Testing App::Ack $App::Ack::VERSION, Perl $], $^X" );
21 t/filetypes.t
@@ -0,0 +1,21 @@
+#!perl -Tw
+
+use warnings;
+use strict;
+
+use Test::More tests => 8;
+
+BEGIN {
+ use_ok( 'App::Ack' );
+}
+