]> git.vpit.fr Git - perl/modules/CPANPLUS-Dist-Gentoo.git/commitdiff
The dists available in cpan/modules/by-module are only those registered in the module...
authorVincent Pit <vince@profvince.com>
Sat, 6 Dec 2008 16:30:43 +0000 (17:30 +0100)
committerVincent Pit <vince@profvince.com>
Sat, 6 Dec 2008 16:30:43 +0000 (17:30 +0100)
lib/CPANPLUS/Dist/Gentoo.pm

index 2c8c0cfcb64aee4073e79959bf90dbd5e8ea1c2c..2e876336ac6045552c7ce42005f3153042631790 100644 (file)
@@ -173,11 +173,12 @@ sub prepare {
 
  $stat->uri('http://search.cpan.org/dist/' . $name);
 
- unless ($name =~ /^([^-]+)/) {
-  error 'Wrong distribution name -- aborting';
+ unless ($author =~ /^(.)(.)/) {
+  error 'Wrong author name -- aborting';
   return 0;
  }
- $stat->src('mirror://cpan/modules/by-module/' . $1 . '/' . $mod->package);
+ $stat->src("mirror://cpan/modules/by-authors/id/$1/$1$2/$author/"
+            . $mod->package);
 
  $stat->license([ qw/Artistic GPL-2/ ]);