Pinto

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN



0.087     2013-06-19 14:47:01 America/Los_Angeles
       
     [INCOMPATIBLE CHANGES]

     - When pulling, Pinto now takes the first satisfactory package
      that it finds among the upstream repositories, rather than
      taking the latest one.  This only matters if you specify
      multiple upstream repositories. To get the old behavior, use the
      new --cascade option on the "pull" and "add" commands.  Thanks
      @hesco for helping me sort this out.

     - The "version" command has been removed.  Now that all Pinto
      components ship together, they all have the same version number.
      So there is no need for a special version command.  If you want
      to know what version of pinto you have, just use the --version
      option.
      
     - Author IDs must now match /^[A-Z]{2}[-A-Z0-9]*$/.  In other
      words, two ASCII letters followed by zero or more ASCII letters,

etc/cpanm  view on Meta::CPAN

                ExtUtils::MakeMaker::_version;
  
            local $1$2;
            \$$2=undef; do {
                $_
            }; \$$2
        };local $^W=0;local$SIG{__WARN__}=sub {};$result=eval($eval);if ($@ or!defined$result){die +{eval=>$eval,line=>$current_parsed_line,file=>$parsefile,err=>$@,}}last}close FH;$result="undef" unless defined$result;return$result}}sub _filter_ppps...
APP_CPANMINUS_PARSEPM

$fatpacked{"App/cpanminus/script.pm"} = <<'APP_CPANMINUS_SCRIPT';
  package App::cpanminus::script;use strict;use Config;use Cwd ();use App::cpanminus;use File::Basename ();use File::Find ();use File::Path ();use File::Spec ();use File::Copy ();use File::Temp ();use Getopt::Long ();use Parse::CPAN::Meta;use Symbol ...
  It appears your cpanm executable was installed via `perlbrew install-cpanm`.
  cpanm --self-upgrade won't upgrade the version of cpanm you're running.
  
  Run the following command to get it upgraded.
  
    perlbrew install-cpanm
  
  DIE
  You are running cpanm from the path where your current perl won't install executables to.
  Because of that, cpanm --self-upgrade won't upgrade the version of cpanm you're running.

etc/cpanm  view on Meta::CPAN

If you enable local::lib, it only removes files from the local::lib
directory.

If you try to uninstall a module in C<perl> directory (i.e. core
module), an error will be thrown.

A dialog wil be prompted to confirm the files to be deleted. If you pass
C<-f> option as well, the dialog will be skipped and uninstallation
will be forced.

=item --cascade-search

B<EXPERIMENTAL>: Specifies whether to cascade search when you specify
multiple mirrors and a mirror doesn't have a module or has a lower
version of the module than requested. Defaults to false.

=item --skip-installed

Specifies whether a module given in the command line is skipped if its latest
version is already installed. Defaults to true.

B<NOTE>: The C<PERL5LIB> environment variable have to be correctly set
for this to work with modules installed using L<local::lib>, unless

lib/App/Pinto/Command/add.pm  view on Meta::CPAN


our $VERSION = '0.097'; # VERSION

#-----------------------------------------------------------------------------

sub opt_spec {
    my ( $self, $app ) = @_;

    return (
        [ 'author=s'                          => 'The ID of the archive author' ],
        [ 'cascade'                           => 'Always pick latest upstream package' ],
        [ 'dry-run'                           => 'Do not commit any changes' ],
        [ 'message|m=s'                       => 'Message to describe the change' ],
        [ 'no-fail'                           => 'Do not fail when there is an error' ],
        [ 'no-index|x=s@'                     => 'Do not index matching packages' ],
        [ 'recurse!'                          => 'Recursively pull prereqs (negatable)' ],
        [ 'pin'                               => 'Pin packages to the stack' ],
        [ 'stack|s=s'                         => 'Put packages into this stack' ],
        [ 'use-default-message|M'             => 'Use the generated message' ],
        [ 'with-development-prerequisites|wd' => 'Also pull prereqs for development' ],
    );

lib/App/Pinto/Command/add.pm  view on Meta::CPAN


=item --author NAME

Set the identity of the distribution author.  The C<NAME> is automatically
forced to uppercase and must match C</^[A-Z]{2}[-A-Z0-9]*$/> (that means
two ASCII letters followed by zero or more ASCII letters, digits, or 
hyphens). Defaults to the C<user> attribute specified in your F<~/.pause>
configuration file if such file exists.  Otherwise, defaults to your 
current login username.

=item --cascade

!! THIS OPTION IS EXPERIMENTAL !!

When searching for a prerequisite package, always take the latest 
satisfactory version of the package found amongst B<all> the upstream 
repositories, rather than just taking the B<first> satisfactory version 
that is found.  Remember that Pinto only searches the upstream
repositories when the local repository does not already contain a
satisfactory version of the package.

lib/App/Pinto/Command/install.pm  view on Meta::CPAN

#------------------------------------------------------------------------------

our $VERSION = '0.097'; # VERSION

#------------------------------------------------------------------------------

sub opt_spec {
    my ( $self, $app ) = @_;

    return (
        [ 'cascade'                 => 'Always pick latest upstream package' ],
        [ 'cpanm-exe|cpanm=s'       => 'Path to the cpanm executable' ],
        [ 'cpanm-options|o:s%'      => 'name=value pairs of cpanm options' ],
        [ 'local-lib|l=s'           => 'install into a local lib directory' ],
        [ 'local-lib-contained|L=s' => 'install into a contained local lib directory' ],
        [ 'message|m=s'             => 'Message to describe the change' ],
        [ 'do-pull'                 => 'pull missing prereqs onto the stack first' ],
        [ 'stack|s=s'               => 'Use the index for this stack' ],

    );
}

lib/App/Pinto/Command/install.pm  view on Meta::CPAN

what to install.

You can also pipe arguments to this command over STDIN.  In that case,
blank lines and lines that look like comments (i.e. starting with "#"
or ';') will be ignored.

=head1 COMMAND OPTIONS

=over 4

=item --cascade

!! THIS OPTION IS EXPERIMENTAL !!

This option only matters when the C<--do-pull> option is also used.

When searching for a prerequisite package, always take the latest 
satisfactory version of the package found amongst B<all> the upstream 
repositories, rather than just taking the B<first> satisfactory version 
that is found.  Remember that Pinto only searches the upstream
repositories when the local repository does not already contain a

lib/App/Pinto/Command/pull.pm  view on Meta::CPAN

#------------------------------------------------------------------------------

our $VERSION = '0.097'; # VERSION

#-----------------------------------------------------------------------------

sub opt_spec {
    my ( $self, $app ) = @_;

    return (
        [ 'cascade'                           => 'Always pick latest upstream package' ],
        [ 'dry-run'                           => 'Do not commit any changes' ],
        [ 'message|m=s'                       => 'Message to describe the change' ],
        [ 'no-fail'                           => 'Do not fail when there is an error' ],
        [ 'recurse!'                          => 'Recursively pull prereqs (negatable)' ],
        [ 'pin'                               => 'Pin the packages to the stack' ],
        [ 'stack|s=s'                         => 'Put packages into this stack' ],
        [ 'use-default-message|M'             => 'Use the generated message' ],
        [ 'with-development-prerequisites|wd' => 'Also pull prereqs for development' ],
    );
}

lib/App/Pinto/Command/pull.pm  view on Meta::CPAN

  SHAKESPEARE/tragedies/Hamlet-4.2.tar.gz  # Ditto, but from a subdirectory

You can also pipe arguments to this command over STDIN.  In that case,
blank lines and lines that look like comments (i.e. starting with "#"
or ';') will be ignored.

=head1 COMMAND OPTIONS

=over 4

=item --cascade

!! THIS OPTION IS EXPERIMENTAL !!

When searching for a package (or one of its prerequisites), always take
the latest satisfactory version of the package found amongst B<all> the
upstream repositories, rather than just taking the B<first> satisfactory
version that is found.  Remember that Pinto only searches the upstream
repositories when the local repository does not already contain a
satisfactory version of the package.

lib/Pinto/Repository.pm  view on Meta::CPAN

    throw 'Invalid arguments';
}

#-------------------------------------------------------------------------------


sub ups_distribution {
    my ( $self, %args ) = @_;

    my $spec = $args{spec};
    my $cascade = $args{cascade} || 0;
    my $dist_url;

    if ( Pinto::Util::itis( $spec, 'Pinto::PackageSpec' ) ) {
        $dist_url = $self->locate( package => $spec->name, version => $spec->version, latest => $cascade );
    }
    elsif ( Pinto::Util::itis( $spec, 'Pinto::DistributionSpec' ) ) {
        $dist_url = $self->locate( distribution => $spec->path );
    }
    else {
        throw 'Invalid arguments';
    }

    throw "Cannot find $spec anywhere" if not $dist_url;

lib/Pinto/Role/Puller.pm  view on Meta::CPAN


#-----------------------------------------------------------------------------

has recurse => (
    is      => 'ro',
    isa     => Bool,
    default => sub { shift->stack->repo->config->recurse },
    lazy    => 1,
);

has cascade => (
    is      => 'ro',
    isa     => Bool,
    default => 0,
);

has pin => (
    is      => 'ro',
    isa     => Bool,
    default => 0,
);

lib/Pinto/Role/Puller.pm  view on Meta::CPAN


    my $dist;
    my $msg;

    if ( $dist = $stack->get_distribution( spec => $target ) ) {
        $msg = "Found $target on stack $stack in $dist";
    }
    elsif ( $dist = $stack->repo->get_distribution( spec => $target ) ) {
        $msg = "Found $target in $dist";
    }
    elsif ( $dist = $stack->repo->ups_distribution( spec => $target, cascade => $self->cascade ) ) {
        $msg = "Found $target in " . $dist->source;
    }

    $self->chrome->show_progress;
    $self->info($msg) if defined $msg;

    return $dist;
}

#-----------------------------------------------------------------------------

lib/Pinto/Schema/Result/Distribution.pm  view on Meta::CPAN

__PACKAGE__->set_primary_key("id");


__PACKAGE__->add_unique_constraint( "author_archive_unique", [ "author", "archive" ] );


__PACKAGE__->has_many(
    "packages",
    "Pinto::Schema::Result::Package",
    { "foreign.distribution" => "self.id" },
    { cascade_copy           => 0, cascade_delete => 0 },
);


__PACKAGE__->has_many(
    "prerequisites",
    "Pinto::Schema::Result::Prerequisite",
    { "foreign.distribution" => "self.id" },
    { cascade_copy           => 0, cascade_delete => 0 },
);


__PACKAGE__->has_many(
    "registrations",
    "Pinto::Schema::Result::Registration",
    { "foreign.distribution" => "self.id" },
    { cascade_copy           => 0, cascade_delete => 0 },
);


with 'Pinto::Role::Schema::Result';

# Created by DBIx::Class::Schema::Loader v0.07033 @ 2013-03-26 11:05:47
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:vQKIXXk8xddyMmBptwvpUg

#-------------------------------------------------------------------------------

lib/Pinto/Schema/Result/Package.pm  view on Meta::CPAN

__PACKAGE__->belongs_to(
    "distribution",
    "Pinto::Schema::Result::Distribution",
    { id            => "distribution" },
    { is_deferrable => 0, on_delete => "CASCADE", on_update => "NO ACTION" },
);


__PACKAGE__->has_many(
    "registrations", "Pinto::Schema::Result::Registration",
    { "foreign.package" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 },
);


with 'Pinto::Role::Schema::Result';

# Created by DBIx::Class::Schema::Loader v0.07033 @ 2013-03-04 12:39:54
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:wYrDViIlHDocM5byRBn1Qg

#------------------------------------------------------------------------------

lib/Pinto/Schema/Result/Revision.pm  view on Meta::CPAN



__PACKAGE__->set_primary_key("id");


__PACKAGE__->add_unique_constraint( "uuid_unique", ["uuid"] );


__PACKAGE__->has_many(
    "ancestry_children", "Pinto::Schema::Result::Ancestry",
    { "foreign.child" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 },
);


__PACKAGE__->has_many(
    "ancestry_parents", "Pinto::Schema::Result::Ancestry",
    { "foreign.parent" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 },
);


__PACKAGE__->has_many(
    "registrations", "Pinto::Schema::Result::Registration",
    { "foreign.revision" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 },
);


__PACKAGE__->has_many(
    "stacks",
    "Pinto::Schema::Result::Stack",
    { "foreign.head" => "self.id" },
    { cascade_copy   => 0, cascade_delete => 0 },
);


with 'Pinto::Role::Schema::Result';

# Created by DBIx::Class::Schema::Loader v0.07033 @ 2013-03-07 12:56:52
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:u3EeZBioyg8H9+azCHQYNA

#------------------------------------------------------------------------------

t/02-bowels/23-pull-multi.t  view on Meta::CPAN


    my $local = Pinto::Tester->new( init_args => { sources => $sources } );
    $local->run_ok( 'Pull', { targets => 'PkgD~1' } );
    $local->registration_ok('JOHN/DistD-1/PkgD~1');
    $local->registration_ok('JOHN/DistC-1/PkgC~1');
}

#------------------------------------------------------------------------------

{
    # Same as last test but with cascade => 1, we should get newer PkgC~2
    # from Source 2, because it is the latest amongst all upstream repos.

    my $local = Pinto::Tester->new( init_args => { sources => $sources } );
    $local->run_ok( 'Pull', { targets => 'PkgD~1', cascade => 1 } );
    $local->registration_ok('JOHN/DistD-1/PkgD~1');
    $local->registration_ok('FRED/DistC-2/PkgC~2');
}

#------------------------------------------------------------------------------

done_testing;



( run in 0.559 second using v1.01-cache-2.11-cpan-49f99fa48dc )