Bug#649834: detect if we are already up to date and if so stop
Alessandro Ghedini
al3xbio at gmail.com
Thu Nov 24 20:14:32 UTC 2011
On Thu, Nov 24, 2011 at 02:58:11PM +0800, jidanni at jidanni.org wrote:
> Package: cpanminus
> Version: 1.5004-1
> Severity: wishlist
> File: /usr/bin/cpanm
>
> Can't this act like apt and tell that we are already up to date on the
> second run?
>
> $ export PERL_CPANM_HOME=/tmp/no-backup/cpanm; cpanm WebService::GData
> !
> ! Can't write to /usr/local/share/perl/5.14.2 and /usr/local/bin: Installing modules to /home/jidanni/perl5
> ! To turn off this warning, you have to do one of the following:
> ! - run me as a root or with --sudo option (to install to /usr/local/share/perl/5.14.2 and /usr/local/bin)
> | - run me with --local-lib option e.g. cpanm --local-lib=~/perl5
> ! - Set PERL_CPANM_OPT="--local-lib=~/perl5" environment variable (in your shell rc file)
> ! - Configure local::lib in your shell to set PERL_MM_OPT etc.
> !
> --> Working on WebService::GData
> Fetching http://search.cpan.org/CPAN/authors/id/S/SH/SHIRIRU/WebService-GData-0.0501.tar.gz ... OK
> Configuring WebService-GData-0.0501 ... OK
> Building and testing WebService-GData-0.0501 ... OK
> Successfully installed WebService-GData-0.0501
> 1 distribution installed
> $ export PERL_CPANM_HOME=/tmp/no-backup/cpanm; cpanm WebService::GData
> !
> ! Can't write to /usr/local/share/perl/5.14.2 and /usr/local/bin: Installing modules to /home/jidanni/perl5
> ! To turn off this warning, you have to do one of the following:
> ! - run me as a root or with --sudo option (to install to /usr/local/share/perl/5.14.2 and /usr/local/bin)
> | - run me with --local-lib option e.g. cpanm --local-lib=~/perl5
> ! - Set PERL_CPANM_OPT="--local-lib=~/perl5" environment variable (in your shell rc file)
> ! - Configure local::lib in your shell to set PERL_MM_OPT etc.
> !
> --> Working on WebService::GData
> Fetching http://search.cpan.org/CPAN/authors/id/S/SH/SHIRIRU/WebService-GData-0.0501.tar.gz ... OK
> Configuring WebService-GData-0.0501 ... OK
> Building and testing WebService-GData-0.0501 ... OK
> Successfully installed WebService-GData-0.0501
> 1 distribution installed
cpanminus does that already by default, if I understood correctly what you
meant.
First run:
% export PERL_CPANM_HOME=/tmp/no-backup/cpanm; cpanm WebService::GData
Successfully installed Sub-Uplevel-0.22
Successfully installed Tree-DAG_Node-1.06
Successfully installed Test-Warn-0.23
Successfully installed Test-Exception-0.31
Successfully installed UNIVERSAL-isa-1.20110614
Successfully installed UNIVERSAL-can-1.20110617
Successfully installed Test-MockObject-1.20110612
Successfully installed Test-Mock-LWP-0.06
Successfully installed WebService-GData-0.0501
9 distributions installed
Second run:
% export PERL_CPANM_HOME=/tmp/no-backup/cpanm; cpanm WebService::GData
WebService::GData is up to date. (0.0501)
My config:
% cpanm -V
cpanm (App::cpanminus) version 1.5004
% echo $PERL_CPANM_OPT
-q -l ~/.perl5
Also see the "--skip-satisfied" option (which mentions also the
"--skip-installed" option, but it doesn't appear to be documented in the
manpage, I'll report that upstream). As far as I can tell from the source
code the "--skip-installed" one is enabled by default, the other is not.
Cheers
--
perl -E'$_=q;$/= @{[@_]};and s;\S+;<inidehG ordnasselA>;eg;say~~reverse'
More information about the pkg-perl-maintainers
mailing list