Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

24 lines (18 sloc) 0.529 kb
package xt::Run;
use strict;
use base qw(Exporter);
our @EXPORT = qw(run last_build_log);
use Capture::Tiny qw(capture);
use File::Temp qw(tempdir);
delete $ENV{PERL_CPANM_OPT};
$ENV{PERL_CPANM_HOME} = tempdir(CLEANUP => 1);
sub run {
my @args = @_;
my @notest = $ENV{NOTEST} ? ("--notest") : ();
return capture { system($^X, "./script/cpanm.PL", @notest, "--quiet", "--reinstall", @args) };
}
sub last_build_log {
open my $log, "<", "$ENV{PERL_CPANM_HOME}/latest-build/build.log";
join '', <$log>;
}
1;
Jump to Line
Something went wrong with that request. Please try again.