line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package ShipIt::Step::CheckYAMLChangeLog; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
763
|
use strict; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
159
|
|
4
|
2
|
|
|
2
|
|
12
|
use warnings; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
61
|
|
5
|
2
|
|
|
2
|
|
3158
|
use Module::Changes; |
|
2
|
|
|
|
|
102846
|
|
|
2
|
|
|
|
|
21
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
our $VERSION = '0.02'; |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
|
11
|
2
|
|
|
2
|
|
164
|
use base 'ShipIt::Step::CheckChangeLog'; |
|
2
|
|
|
|
|
6
|
|
|
2
|
|
|
|
|
2267
|
|
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
sub check_file_for_version { |
15
|
1
|
|
|
1
|
0
|
19
|
my ($self, $file, $version) = @_; |
16
|
1
|
|
|
|
|
39
|
my $parser = Module::Changes->make_object_for_type('parser_yaml'); |
17
|
1
|
|
|
|
|
59019
|
my $changes = $parser->parse_from_file($file); |
18
|
1
|
|
|
|
|
12332
|
for my $release ($changes->releases) { |
19
|
2
|
|
|
|
|
21
|
my $rel_version = $release->version_as_string; |
20
|
2
|
100
|
|
|
|
363
|
return 1 if $rel_version =~ /^v?\Q$version\E$/; |
21
|
|
|
|
|
|
|
} |
22
|
0
|
|
|
|
|
|
warn "No mention of version '$version' in changelog file '$file'\n"; |
23
|
0
|
|
|
|
|
|
return 0; |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
1; |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
__END__ |