App-PAUSE-CheckPerms

 view release on metacpan or  search on metacpan

bin/pause-checkperms  view on Meta::CPAN

#!/usr/local/bin/perl
use strict;
use warnings;
use App::PAUSE::CheckPerms;

my $app = App::PAUSE::CheckPerms->new_with_options();

$app->execute();

=head1 NAME

pause-checkperms - check PAUSE permissions are consistent for all modules in a dist

=head1 SYNOPSIS

 pause-checkperms --user NEILB

=head1 DESCRIPTION

B<pause-checkperms> looks at the PAUSE permissions for all modules in
CPAN distributions, and lets you know if they're consistent.
It will typically be used to check all your CPAN distributions.
My PAUSE id is C<NEILB>, so I'd run the following:

 pause-checkperms --user NEILB

This will check all dists where I have permissions for at least one
module in the dist. It will only display details of distributions where
the permissions are inconsistent.
At the time I was writing this script, it would
generate the following output for me:

 PAUSE-Permissions
   PAUSE::Permissions                 |      NEILB
   PAUSE::Permissions::Entry          |      NEILB
   PAUSE::Permissions::EntryIterator  |      NEILB
   PAUSE::Permissions::Module         | ANDK neilb
   PAUSE::Permissions::ModuleIterator |      NEILB

This shows that I'm the owner of all modules in the C<PAUSE-Permissions>
dist, except for L<PAUSE::Permissions::Module>, which C<ANDK> is the owner of,
and I have co-maint permissions.
The owner's PAUSE id is shown in upper case, and co-maints are listed in
lower case.

The permissions shown above are problematic for two reasons:

=over 4

=item *

Neither ANDK or NEILB can grant co-maint permissions for the whole
distribution. Only the owner of a module can grant co-maint.

=item *

Even though he owns one module, ANDK couldn't release this distribution.
If he tried to, the I<indexing> stage of PAUSE would fail for the
modules where ANDK doesn't have permissions.

In search.cpan.org this would then be flagged as

 * * UNAUTHORISED RELEASE * *

You can use the PAUSE web interface to correct any inconsistent permissions.
In this case I'll have to ask ANDK to transfer ownership 
of C<PAUSE::Permissions::Module> to me.

=back

If you don't specify a user, pause-checkperms will check all
distributions on CPAN.

=head1 PAUSE Permissions model

The PAUSE permissions model is based on I<modules> and not I<distributions>.
If you're not familiar with the PAUSE permissions model,
read the documentation for L<PAUSE::Permissions>, which explains it.

=head1 CAVEAT



( run in 2.004 seconds using v1.01-cache-2.11-cpan-39bf76dae61 )