line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Minilla::CLI::Install; |
2
|
1
|
|
|
1
|
|
7
|
use strict; |
|
1
|
|
|
|
|
4
|
|
|
1
|
|
|
|
|
30
|
|
3
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
30
|
|
4
|
1
|
|
|
1
|
|
12
|
use utf8; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
43
|
|
5
|
|
|
|
|
|
|
|
6
|
1
|
|
|
1
|
|
26
|
use Minilla::WorkDir; |
|
1
|
|
|
|
|
5
|
|
|
1
|
|
|
|
|
28
|
|
7
|
1
|
|
|
1
|
|
7
|
use Minilla::Util qw(cmd parse_options); |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
221
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub run { |
10
|
0
|
|
|
0
|
0
|
|
my ($self, @args) = @_; |
11
|
|
|
|
|
|
|
|
12
|
0
|
|
|
|
|
|
my $test = 1; |
13
|
0
|
|
|
|
|
|
parse_options( |
14
|
|
|
|
|
|
|
\@args, |
15
|
|
|
|
|
|
|
'test!' => \$test, |
16
|
|
|
|
|
|
|
); |
17
|
|
|
|
|
|
|
|
18
|
0
|
|
|
|
|
|
my $project = Minilla::Project->new(); |
19
|
0
|
|
|
|
|
|
my $work_dir = $project->work_dir(); |
20
|
|
|
|
|
|
|
|
21
|
0
|
0
|
|
|
|
|
if ($test) { |
22
|
0
|
|
|
|
|
|
local $ENV{RELEASE_TESTING} = 1; |
23
|
0
|
|
|
|
|
|
$work_dir->dist_test(); |
24
|
|
|
|
|
|
|
} |
25
|
0
|
|
|
|
|
|
my $tar = $work_dir->dist(); |
26
|
|
|
|
|
|
|
|
27
|
0
|
|
|
|
|
|
cmd( |
28
|
|
|
|
|
|
|
'cpanm', |
29
|
|
|
|
|
|
|
'--notest', |
30
|
|
|
|
|
|
|
$tar |
31
|
|
|
|
|
|
|
); |
32
|
0
|
0
|
|
|
|
|
unlink($tar) unless Minilla->debug; |
33
|
|
|
|
|
|
|
} |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
1; |
36
|
|
|
|
|
|
|
__END__ |