Closed hoelzro closed 8 years ago
ack1 did not do this
$ ack1 --version
ack 1.96
Running under Perl 5.10.1 at /usr/local/bin/perl
Copyright 2005-2011 Andy Lester.
This program is free software. You may modify or distribute it
under the terms of the Artistic License v2.0.
$ echo "\n\n\n" | ack1 '^(\s+)' | wc -l
0
Zero for me:
$ echo "\n\n\n" | ack '^\s+' | wc -l
0
$ ack --version
ack 2.14
Running under Perl 5.22.0 at /usr/bin/perl
Copyright 2005-2014 Andy Lester.
This program is free software. You may modify or distribute it
under the terms of the Artistic License v2.0.
Oops, I think I forgot to mark this as fixed when I fixed this.
For example:
This is because
\s
is matching the newline characters.