Acme-CPANAuthors-Acme-CPANAuthors-Authors

 view release on metacpan or  search on metacpan

lib/Acme/CPANAuthors/Acme/CPANAuthors/Authors.pm  view on Meta::CPAN

             }
             elsif ($authsec) {    # No more Authors in 02packages
                 while ($data
                     =~ m[^(?:Acme::CPANAuthors(?:::(\S+))?).+\w/\w\w/(\w+)/.+$]mg
                     )
                 {   $authors{$2} //= [];
                     push @{$authors{$2}}, $1;
                 }
                 my %old = authors();    # Current authors
                 my @new = grep { defined $old{$_} ? () : $_ } keys %authors;
                 print scalar(@new)
                     . " new Acme::CPANAuthors authors to add\n";
                 return if !@new;
                 require MetaCPAN::API;
                 my $mcpan = MetaCPAN::API->new();
                 binmode(STDOUT, ':utf8');

                 for my $id (sort @new) {
                     my $author = $mcpan->author($id);
                     printf "    %s => q[%s], # %s\n", $id, $author->{name},
                         join ', ', map { 'A::C::' . $_ } @{$authors{$id}};
                 }
                 exit    # We're done
             }
             }
        }
        )->{success};
}
1;

scripts/author_info.pl  view on Meta::CPAN

use strict;
use Acme::CPANAuthors;
die "usage: $0 PAUSE_ID [PAUSE_ID ...]\n" unless @ARGV;
my $authors
    = Acme::CPANAuthors->new("Acme::CPANAuthors::Acme::CPANAuthors::Authors");
for my $id (@ARGV) {
    $id = uc $id;
    my $name     = $authors->name($id) || $id;
    my @dists    = $authors->distributions($id);
    my $kwalitee = $authors->kwalitee($id);
    print "$name has published ", ~~ @dists, " distributions:\n";
    @dists = sort { lc($a->dist) cmp lc($b->dist) } @dists;
    for my $dist (@dists) {
        printf " - %s v%s, kwalitee %s\n",
            $dist->dist, $dist->version,
            $kwalitee->{distributions}{$dist->dist}{kwalitee},
            ;
    }
    print $/ if @ARGV > 1;
}

# Stolen from Acme::CPANAuthors::French

scripts/basic_info.pl  view on Meta::CPAN

#!perl -I../lib
use strict;
use warnings;
use Acme::CPANAuthors;
my $authors
    = Acme::CPANAuthors->new('Acme::CPANAuthors::Acme::CPANAuthors::Authors');
printf 'ACACA v%s contains %d authors and is brought to you by %s.',
    $Acme::CPANAuthors::Acme::CPANAuthors::Authors::VERSION, $authors->count,
    $authors->name('SANKO');



( run in 1.047 second using v1.01-cache-2.11-cpan-de7293f3b23 )