App-Magpie

 view release on metacpan or  search on metacpan

lib/App/Magpie/Action/Old.pm  view on Meta::CPAN

with 'App::Magpie::Role::Logging';
with 'App::Magpie::Role::RunningCommand';



sub run {
    my ($self) = @_;
    my %category;

    my $outfile = path( "/tmp/cpan-o.stdout" );
    if ( $ENV{MAGPIE_REUSE_CPAN_O_OUTPUT} ) {
        $self->log( "re-using cpan -O output from $outfile" );
    } else {
        my $cmd = "cpan -O >$outfile 2>/tmp/cpan-o.stderr";
        $self->log( "running: $cmd" );
        system("$cmd") == 0
            or $self->log_fatal( "command [$cmd] exited with value " . ($?>>8) );
    }
    my @lines = $outfile->lines;

    # A file where will we store ignored / rejected lines from cpan -O



( run in 0.350 second using v1.01-cache-2.11-cpan-c6e0e5ac2a7 )