App-pmodinfo
view release on metacpan or search on metacpan
code repository is located on github. Feel free to send a bug report or
a pull request.
<http://www.github.com/maluco/App-pmodinfo>
SEE ALSO
Module::Metadata, Module::CoreList, Module::Build, Parse::CPAN::Meta,
ExtUtils::Installed.
ACKNOWLEDGE
cpanminus, for the check_module, prompt function and inspiration. :-)
AUTHOR
Thiago Rondon <thiago@nsms.com.br>
COPYRIGHT AND LICENSE
This software is copyright (c) 2011 by Thiago Rondon.
This is free software; you can redistribute it and/or modify it under
the same terms as the Perl 5 programming language system itself.
lib/App/pmodinfo.pm view on Meta::CPAN
my $cpan_version = $self->get_last_version_from_cpan($module);
next unless $cpan_version and $local_version;
next if $cpan_version eq $local_version;
print "$module local version: $local_version, last version in cpan: $cpan_version\n";
push( @need_update, $module );
}
if ( scalar(@need_update) ) {
my $ans = lc $self->prompt( "Do you need to update this modules now ? (y/n)", "n" );
$self->update_modules(@need_update) if $ans eq 'y';
}
else {
print "already up to date.";
}
exit 0;
}
sub prompt {
my ( $self, $mess, $def ) = @_;
my $isa_tty = -t STDIN && ( -t STDOUT || !( -f STDOUT || -c STDOUT ) );
my $dispdef = defined $def ? "[$def] " : " ";
$def = defined $def ? $def : "";
if ( ( !$isa_tty && eof STDIN ) ) {
return $def;
}
lib/App/pmodinfo.pm view on Meta::CPAN
L<http://www.github.com/maluco/App-pmodinfo>
=head1 SEE ALSO
L<Module::Metadata>, L<Module::CoreList>, L<Module::Build>,
L<Parse::CPAN::Meta>, L<ExtUtils::Installed>.
=head1 ACKNOWLEDGE
L<cpanminus>, for the check_module, prompt function and inspiration. :-)
=head1 AUTHOR
Thiago Rondon <thiago@nsms.com.br>
=head1 COPYRIGHT AND LICENSE
This software is copyright (c) 2011 by Thiago Rondon.
This is free software; you can redistribute it and/or modify it under
( run in 0.860 second using v1.01-cache-2.11-cpan-0b5f733616e )