line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package File::Find::CaseCollide; |
2
|
|
|
|
|
|
|
$File::Find::CaseCollide::VERSION = '0.2.0'; |
3
|
2
|
|
|
2
|
|
88853
|
use strict; |
|
2
|
|
|
|
|
13
|
|
|
2
|
|
|
|
|
59
|
|
4
|
2
|
|
|
2
|
|
13
|
use warnings; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
52
|
|
5
|
2
|
|
|
2
|
|
40
|
use 5.014; |
|
2
|
|
|
|
|
7
|
|
6
|
2
|
|
|
2
|
|
1078
|
use File::Find::Object (); |
|
2
|
|
|
|
|
23856
|
|
|
2
|
|
|
|
|
48
|
|
7
|
2
|
|
|
2
|
|
1078
|
use Moo; |
|
2
|
|
|
|
|
23269
|
|
|
2
|
|
|
|
|
11
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
has '_results' => ( is => 'rw' ); |
10
|
|
|
|
|
|
|
has '_ffo' => ( is => 'rw' ); |
11
|
|
|
|
|
|
|
has 'dir' => ( is => 'ro' ); |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
sub _iter |
14
|
|
|
|
|
|
|
{ |
15
|
157
|
|
|
157
|
|
290
|
my ($self) = @_; |
16
|
157
|
100
|
|
|
|
390
|
if ( my $r = $self->_ffo->next_obj() ) |
17
|
|
|
|
|
|
|
{ |
18
|
155
|
100
|
|
|
|
33402
|
if ( $r->is_dir() ) |
19
|
|
|
|
|
|
|
{ |
20
|
61
|
|
|
|
|
101
|
my %found; |
21
|
61
|
|
|
|
|
78
|
foreach my $fn ( @{ $self->_ffo->get_current_node_files_list() } ) |
|
61
|
|
|
|
|
177
|
|
22
|
|
|
|
|
|
|
{ |
23
|
153
|
|
|
|
|
8001
|
push @{ $found{ lc $fn } }, $fn; |
|
153
|
|
|
|
|
472
|
|
24
|
|
|
|
|
|
|
} |
25
|
61
|
|
|
|
|
581
|
my @positives = grep { @{ $found{$_} } > 1 } ( keys %found ); |
|
153
|
|
|
|
|
198
|
|
|
153
|
|
|
|
|
349
|
|
26
|
|
|
|
|
|
|
|
27
|
61
|
50
|
|
|
|
233
|
if (@positives) |
28
|
|
|
|
|
|
|
{ |
29
|
|
|
|
|
|
|
$self->_results->{ $r->path() } = |
30
|
0
|
|
|
|
|
0
|
+{ map { $_ => $found{$_} } @positives }; |
|
0
|
|
|
|
|
0
|
|
31
|
|
|
|
|
|
|
} |
32
|
|
|
|
|
|
|
} |
33
|
155
|
|
|
|
|
515
|
return 1; |
34
|
|
|
|
|
|
|
} |
35
|
2
|
|
|
|
|
402
|
return; |
36
|
|
|
|
|
|
|
} |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
sub find |
39
|
|
|
|
|
|
|
{ |
40
|
2
|
|
|
2
|
1
|
1348
|
my ($self) = @_; |
41
|
|
|
|
|
|
|
|
42
|
2
|
|
|
|
|
11
|
$self->_results( {} ); |
43
|
2
|
|
|
|
|
23
|
$self->_ffo( File::Find::Object->new( {}, $self->dir ) ); |
44
|
|
|
|
|
|
|
|
45
|
2
|
|
|
|
|
488
|
while ( $self->_iter ) |
46
|
|
|
|
|
|
|
{ |
47
|
|
|
|
|
|
|
} |
48
|
|
|
|
|
|
|
|
49
|
2
|
|
|
|
|
11
|
return $self->_results; |
50
|
|
|
|
|
|
|
} |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
1; |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
__END__ |