line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
1
|
|
|
1
|
|
2045
|
use 5.008; # utf8 |
|
1
|
|
|
|
|
4
|
|
|
1
|
|
|
|
|
52
|
|
2
|
1
|
|
|
1
|
|
7
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
46
|
|
3
|
1
|
|
|
1
|
|
7
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
92
|
|
4
|
1
|
|
|
1
|
|
1022
|
use utf8; |
|
1
|
|
|
|
|
12
|
|
|
1
|
|
|
|
|
9
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
package Git::PurePerl::Walker::OnCommit::CallBack; |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
our $VERSION = '0.004000'; |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
# ABSTRACT: Execute a sub() for each commit |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
our $AUTHORITY = 'cpan:KENTNL'; # AUTHORITY |
13
|
|
|
|
|
|
|
|
14
|
1
|
|
|
1
|
|
413
|
use Moose qw( with has ); |
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
use MooseX::Types::Moose qw( CodeRef ); |
16
|
|
|
|
|
|
|
use namespace::autoclean; |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
with qw( Git::PurePerl::Walker::Role::OnCommit ); |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
has callback => ( |
55
|
|
|
|
|
|
|
handles => { do_callback => 'execute', }, |
56
|
|
|
|
|
|
|
is => 'rw', |
57
|
|
|
|
|
|
|
isa => CodeRef, |
58
|
|
|
|
|
|
|
required => 1, |
59
|
|
|
|
|
|
|
traits => [qw( Code )], |
60
|
|
|
|
|
|
|
); |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
sub handle { |
69
|
|
|
|
|
|
|
my ( $self, $commit ) = @_; |
70
|
|
|
|
|
|
|
$self->do_callback($commit); |
71
|
|
|
|
|
|
|
return $self; |
72
|
|
|
|
|
|
|
} |
73
|
|
|
|
|
|
|
|
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
|
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
|
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
|
80
|
|
|
|
|
|
|
## no critic ( Subroutines::ProhibitBuiltinHomonyms ) |
81
|
|
|
|
|
|
|
sub reset { |
82
|
|
|
|
|
|
|
return shift; |
83
|
|
|
|
|
|
|
} |
84
|
|
|
|
|
|
|
## use critic |
85
|
|
|
|
|
|
|
|
86
|
|
|
|
|
|
|
no Moose; |
87
|
|
|
|
|
|
|
__PACKAGE__->meta->make_immutable; |
88
|
|
|
|
|
|
|
1; |
89
|
|
|
|
|
|
|
|
90
|
|
|
|
|
|
|
__END__ |
91
|
|
|
|
|
|
|
|
92
|
|
|
|
|
|
|
=pod |
93
|
|
|
|
|
|
|
|
94
|
|
|
|
|
|
|
=encoding UTF-8 |
95
|
|
|
|
|
|
|
|
96
|
|
|
|
|
|
|
=head1 NAME |
97
|
|
|
|
|
|
|
|
98
|
|
|
|
|
|
|
Git::PurePerl::Walker::OnCommit::CallBack - Execute a sub() for each commit |
99
|
|
|
|
|
|
|
|
100
|
|
|
|
|
|
|
=head1 VERSION |
101
|
|
|
|
|
|
|
|
102
|
|
|
|
|
|
|
version 0.004000 |
103
|
|
|
|
|
|
|
|
104
|
|
|
|
|
|
|
=head1 CONSTRUCTOR ARGUMENTS |
105
|
|
|
|
|
|
|
|
106
|
|
|
|
|
|
|
=head2 callback |
107
|
|
|
|
|
|
|
|
108
|
|
|
|
|
|
|
=head1 ATTRIBUTES |
109
|
|
|
|
|
|
|
|
110
|
|
|
|
|
|
|
=head2 callback |
111
|
|
|
|
|
|
|
|
112
|
|
|
|
|
|
|
=head1 ATTRIBUTE GENERATED METHODS |
113
|
|
|
|
|
|
|
|
114
|
|
|
|
|
|
|
=head2 callback |
115
|
|
|
|
|
|
|
|
116
|
|
|
|
|
|
|
=head2 do_callback |
117
|
|
|
|
|
|
|
|
118
|
|
|
|
|
|
|
=head1 INHERITED METHODS |
119
|
|
|
|
|
|
|
|
120
|
|
|
|
|
|
|
=head2 for_repository |
121
|
|
|
|
|
|
|
|
122
|
|
|
|
|
|
|
L<< C<Git::PurePerl::B<Walker::Role::HasRepo>-E<gt>I<for_repository( $repo )>>|Git::PurePerl::Walker::Role::HasRepo/for_repository >> |
123
|
|
|
|
|
|
|
|
124
|
|
|
|
|
|
|
=head2 clone |
125
|
|
|
|
|
|
|
|
126
|
|
|
|
|
|
|
L<< C<MooseX::B<Clone>-E<gt>I<clone( %params )>>|MooseX::Clone/clone-params >> |
127
|
|
|
|
|
|
|
|
128
|
|
|
|
|
|
|
=head2 _repo |
129
|
|
|
|
|
|
|
|
130
|
|
|
|
|
|
|
L<< C<Git::PurePerl::B<Walker::Role::HasRepo>-E<gt>I<_repo( $repo )>>|Git::PurePerl::Walker::Role::HasRepo/_repo >> |
131
|
|
|
|
|
|
|
|
132
|
|
|
|
|
|
|
=head1 CONSUMED ROLES |
133
|
|
|
|
|
|
|
|
134
|
|
|
|
|
|
|
=head2 Git::PurePerl::Walker::Role::OnCommit |
135
|
|
|
|
|
|
|
|
136
|
|
|
|
|
|
|
L<< C<Git::PurePerl::B<Walker::Role::OnCommit>>|Git::PurePerl::Walker::Role::OnCommit >> |
137
|
|
|
|
|
|
|
|
138
|
|
|
|
|
|
|
=head1 ROLE SATISFYING METHODS |
139
|
|
|
|
|
|
|
|
140
|
|
|
|
|
|
|
=head2 handle |
141
|
|
|
|
|
|
|
|
142
|
|
|
|
|
|
|
L<< C<Git::PurePerl::B<Walker::Role::OnCommit>-E<gt>I<handle( $commit )>>|Git::PurePerl::Walker::Role::OnCommit/handle >> |
143
|
|
|
|
|
|
|
|
144
|
|
|
|
|
|
|
=head2 reset |
145
|
|
|
|
|
|
|
|
146
|
|
|
|
|
|
|
L<< C<Git::PurePerl::B<Walker::Role::OnCommit>-E<gt>I<reset()>>|Git::PurePerl::Walker::Role::OnCommit/reset >> |
147
|
|
|
|
|
|
|
|
148
|
|
|
|
|
|
|
=head1 AUTHOR |
149
|
|
|
|
|
|
|
|
150
|
|
|
|
|
|
|
Kent Fredric <kentnl@cpan.org> |
151
|
|
|
|
|
|
|
|
152
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
153
|
|
|
|
|
|
|
|
154
|
|
|
|
|
|
|
This software is copyright (c) 2014 by Kent Fredric <kentnl@cpan.org>. |
155
|
|
|
|
|
|
|
|
156
|
|
|
|
|
|
|
This is free software; you can redistribute it and/or modify it under |
157
|
|
|
|
|
|
|
the same terms as the Perl 5 programming language system itself. |
158
|
|
|
|
|
|
|
|
159
|
|
|
|
|
|
|
=cut |