blib/lib/Minilla/Release/CheckUntrackedFiles.pm | |||
---|---|---|---|
Criterion | Covered | Total | % |
statement | 12 | 16 | 75.0 |
branch | 0 | 2 | 0.0 |
condition | n/a | ||
subroutine | 4 | 5 | 80.0 |
pod | 0 | 1 | 0.0 |
total | 16 | 24 | 66.6 |
line | stmt | bran | cond | sub | pod | time | code |
---|---|---|---|---|---|---|---|
1 | package Minilla::Release::CheckUntrackedFiles; | ||||||
2 | 1 | 1 | 1019 | use strict; | |||
1 | 4 | ||||||
1 | 28 | ||||||
3 | 1 | 1 | 5 | use warnings; | |||
1 | 2 | ||||||
1 | 23 | ||||||
4 | 1 | 1 | 5 | use utf8; | |||
1 | 2 | ||||||
1 | 6 | ||||||
5 | |||||||
6 | 1 | 1 | 24 | use Minilla::Logger; | |||
1 | 2 | ||||||
1 | 161 | ||||||
7 | |||||||
8 | sub run { | ||||||
9 | 0 | 0 | 0 | my ($self, $project, $opts) = @_; | |||
10 | |||||||
11 | 0 | 0 | if ( my $unk = `git ls-files -z --others --exclude-standard` ) { | ||||
12 | 0 | $unk =~ s/\0/\n/g; | |||||
13 | 0 | errorf("Unknown local files:\n$unk\n\nUpdate .gitignore, or git add them\n"); | |||||
14 | } | ||||||
15 | } | ||||||
16 | |||||||
17 | 1; | ||||||
18 |