--- a/lib/App/cpanminus/https.pm +++ b/lib/App/cpanminus/https.pm @@ -1,4 +1,4 @@ -package App::cpanminus; +package App::cpanminus::https; our $VERSION = "1.7047"; =encoding utf8 --- a/lib/App/cpanminus/https/fatscript.pm +++ b/lib/App/cpanminus/https/fatscript.pm @@ -1,4 +1,4 @@ -package App::cpanminus::fatscript; +package App::cpanminus::https::fatscript; # # This is a pre-compiled source code for the cpanm (cpanminus) program. # For more details about how to install cpanm, go to the following URL: @@ -469,7 +469,7 @@ mirrors => [], mirror_only => undef, mirror_index => undef, - cpanmetadb => "http://cpanmetadb.plackperl.org/v1.0/", + cpanmetadb => "https://cpanmetadb.plackperl.org/v1.0/", perl => $^X, argv => [], local_lib => undef, @@ -565,7 +565,7 @@ 'h|help' => sub { $self->{action} = 'show_help' }, 'V|version' => sub { $self->{action} = 'show_version' }, 'perl=s' => sub { - $self->diag("--perl is deprecated since it's known to be fragile in figuring out dependencies. Run `$_[1] -S cpanm` instead.\n", 1); + $self->diag("--perl is deprecated since it's known to be fragile in figuring out dependencies. Run `$_[1] -S cpanms` instead.\n", 1); $self->{perl} = $_[1]; }, 'l|local-lib=s' => sub { $self->{local_lib} = $self->maybe_abs($_[1]) }, @@ -810,7 +810,7 @@ } } - $self->chat("cpanm (App::cpanminus) $VERSION on perl $] built for $Config{archname}\n" . + $self->chat("cpanms (App::cpanminus) $VERSION on perl $] built for $Config{archname}\n" . "Work directory is $self->{base}\n"); } @@ -926,7 +926,7 @@ sub search_metacpan { my($self, $module, $version, $dev_release) = @_; - my $metacpan_uri = 'http://fastapi.metacpan.org/v1/download_url/'; + my $metacpan_uri = 'https://fastapi.metacpan.org/v1/download_url/'; my $url = $metacpan_uri . $module; @@ -943,7 +943,7 @@ if ($dist_meta && $dist_meta->{download_url}) { (my $distfile = $dist_meta->{download_url}) =~ s!.+/authors/id/!!; local $self->{mirrors} = $self->{mirrors}; - $self->{mirrors} = [ 'http://cpan.metacpan.org' ]; + $self->{mirrors} = [ 'https://cpan.metacpan.org' ]; return $self->cpan_module($module, $distfile, $dist_meta->{version}); } @@ -1019,7 +1019,7 @@ for my $try (sort { $b->{version_obj} cmp $a->{version_obj} } @found) { if ($self->satisfy_version($module, $try->{version_obj}, $version)) { local $self->{mirrors} = $self->{mirrors}; - unshift @{$self->{mirrors}}, 'http://backpan.perl.org' + unshift @{$self->{mirrors}}, 'https://backpan.perl.org' unless $try->{latest}; return $self->cpan_module($module, $try->{distfile}, $try->{version}); } @@ -1099,7 +1099,7 @@ sub show_version { my $self = shift; - print "cpanm (App::cpanminus) version $VERSION ($0)\n"; + print "cpanms (App::cpanminus) version $VERSION ($0)\n"; print "perl version $] ($^X)\n\n"; print " \%Config:\n"; @@ -1125,7 +1125,7 @@ my $self = shift; if ($_[0]) { - print <resolve_path($base); if ($self->{self_contained}) { @@ -1671,7 +1671,7 @@ sub configure_mirrors { my $self = shift; unless (@{$self->{mirrors}}) { - $self->{mirrors} = [ 'http://www.cpan.org' ]; + $self->{mirrors} = [ 'https://www.cpan.org' ]; } for (@{$self->{mirrors}}) { s!^/!file:///!; @@ -3180,7 +3180,7 @@ sub has_working_lwp { my($self, $mirrors) = @_; - my $https = grep /^https:/, @$mirrors; + my $https = @$mirrors == 0 || grep /^https:/, @$mirrors; # default mirrors use https eval { require LWP::UserAgent; # no fatpack LWP::UserAgent->VERSION(5.802);