Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

grep: search results listed in lowercase #776

Merged
merged 1 commit into from
Oct 31, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions bin/grep
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ use File::Spec;
use File::Temp qw();
use Getopt::Std;

our $VERSION = '1.007';
our $VERSION = '1.008';

$| = 1; # autoflush output

Expand Down Expand Up @@ -171,15 +171,15 @@ sub parse_args {
}
};
my $cls_fgrep_i = sub {
$_ = lc $_;
my $s = lc $_;
for my $pattern (@patterns) {
$Matches++ if index($_, lc $pattern) != -1;
$Matches++ if index($s, lc $pattern) != -1;
}
};
my $cls_fgrep_iv = sub {
$_ = lc $_;
my $s = lc $_;
for my $pattern (@patterns) {
$Matches++ if index($_, lc $pattern) == -1;
$Matches++ if index($s, lc $pattern) == -1;
}
};
my $cls_fgrep_x = sub {
Expand Down
Loading