#!/home/grinnz/projects/cpandoc-browser/perls/5.38.2/bin/perl # ABSTRACT: Curate a custom repository of Perl modules # PODNAME: pinto #----------------------------------------------------------------------------- use strict; use warnings; #----------------------------------------------------------------------------- our $VERSION = '0.14'; # VERSION #----------------------------------------------------------------------------- my $home_var = 'PINTO_HOME'; my $home_dir = $ENV{$home_var}; if ($home_dir) { require File::Spec; my $lib_dir = File::Spec->catfile($home_dir, qw(lib perl5)); die "$home_var ($home_dir) does not exist!\n" unless -e $home_dir; eval qq{use lib '$lib_dir'; 1} or die $@; ## no critic (Eval) } unless ( eval {require App::Pinto; 1} ) { die $home_dir ? $@ : $@ . "Do you need to set $home_var?\n"; } #----------------------------------------------------------------------------- exit App::Pinto->run if not caller; #----------------------------------------------------------------------------- 1; __END__ =pod =encoding UTF-8 =for :stopwords Jeffrey Ryan Thalhammer =head1 NAME pinto - Curate a custom repository of Perl modules =head1 VERSION version 0.14 =head1 SYNOPSIS pinto --root=REPOSITORY_ROOT [global options] COMMAND [command options] [args] =head1 DESCRIPTION pinto is a tool for creating and managing a custom CPAN-like repository of Perl modules. The purpose of such a repository is to provide a stable, curated stack of dependencies from which you can reliably build, test, and deploy your application using the standard Perl tool chain. pinto provides various commands for gathering and managing distribution dependencies within the repository, so that you can control precisely which dependencies go into your application. =head1 COMMANDS pinto supports several commands that perform various operations on your repository, or report information about your repository. To get a listing of all the available commands: $> pinto commands Each command has its own options and arguments. To get a brief summary: $> pinto help COMMAND To see the complete manual for a command: $> pinto manual COMMAND =head1 GLOBAL OPTIONS The following options are available for all commands. =over 4 =item --root DIRECTORY | URI =item -r DIRECTORY | URI Specifies the root of your repository. This is mandatory for (almost) all commands unless you set it via the C environment variable. The root can be the path to a local directory or an equivalent C URI. The root can also be the URI where a L server is listening. Depending on your server configuration, you may need to specify the port number in the URI, which is usually 3111. =item --color =item --colour =item --no-color =item --no-colour Enable or disable colorized command output. By default, color is enabled unless the output is being sent to a pipe or file. Set the C environment variable to disable color by default. =item --password PASS =item -p PASS The password to use for server authentication. This is only relevant if using a remote repository. If the PASS is "-" then you will be prompted for a password. =item --quiet =item -q Report only fatal errors. This option silently overrides the C<--verbose> options. Also suppresses the progress meter. Note: The progress meter is always suppressed when using a remote repository. This will hopefully be fixed a future release. =item --username NAME =item -u NAME The username to user for server authentication. This is only relevant if using a remote repository. Defaults to your current login. =item --verbose =item -v Display more diagnostic messages. This switch can be repeated multiple times for greater effect. Diagnostic messages are always sent to STDERR. =back =head1 CONFIGURATION Each repository has a configuration file that lives inside the repository at F<.pinto/config/pinto.ini>. This file is generated for you with default values when you create the repository. You can influence the initial value for some of the properties when you run the L command. Thereafter, you can change these properties by editing the configuraiton file directly. The following configuration parameters are supported: =over 4 =item sources = URL1 [URL2 URL3 ...] This is a space-delimited list of the URLs for the upstream repositories that this repository will pull archives from. These can point to CPAN mirrors, minicpan mirrors, or stacks within other Pinto repositories. Pinto will search the source repositories in the order they are listed here. The default value is C. =item target_perl_version = X.X.X Sets the default C property for all new stacks. Otherwise, all new stacks will target the version of perl that you first used to create the repository. You can always configure the target perl for each stack independently by using the L command. =item intermingle = 1 | 0 If true, stacks will be allowed to "intermingle" distributions that have partially overlapping packages. This makes pinto behave like PAUSE which allows a package to remain in the index until it is replaced by a distribution containing the same package. Thus, it becomes possible to have an index that contains just C of the packages in a particular distribution. This typically occurrs when a package in a prior release is absent from a subsequent release. The default is false. =back B The above configuration properties are global -- they affect every stack in the repository. They also have a major affect on how the repository behaves. For these reasons, it is generally unwise to change these parameters once you have established the repository and filled it with content. If you do change them, be sure and notify your team about it. Each stack also has some stack-specific configuration properties. Those can be shown or set using the L command. =head1 ENVIRONMENT VARIABLES The following environment variables influence the behavior of pinto. If you have installed pinto as a stand-alone application as described in L, then the best place to set these variables is in your F<~/.pintorc> file. =over 4 =item C Sets the default path or URL of the pinto repository, if the C<--root> is not specified. The C<--root> is required for almost all commands. So if you usually only work with one repository, then setting this can save you quite a bit of typing. =item C Sets the path to editor application that will be used to compose log messages. If not set, defaults to C or C. If none of those are set, either C, C, or C will be used (in that order). =item C =item C If set to a true value, suppresses color in all command output. =item C A comma-separated list of exactly three color names. Any name supported by L is allowed. These will be the colors that pinto uses to colorize various output. For example: PINTO_PALETTE='red, light blue, green on_white' Listing too many or too few colors will cause an exception, as will using an invalid color name. For backward compatibility the variables C and C can also be used (but they are deprecated). =item C Sets the default username when C<--username> is not specified. This is only used for authentication with a L server. Defaults to your current shell username. =item C Sets the default author identity when the C<--author> option is not specified (currently, only used by the L command). Defaults to your current shell username. By PAUSE convention, all author id's are forced to uppercase. =item C Sets the path to the pager application that will be used to paginate output from each command. Defaults to C. If none of these are set, then no pager is used. =item C Sets the options that will be passed to the pager (if there is one). For example, you could use the C<-R> option to instruct C to pass through the colors that pinto usually displays: export PINTO_PAGER_OPTIONS=-R Most pagers have their own environment variables to control their default behavior. C gives you a way to set defaults that are specific to when you are using it with pinto. =item C Sets the default style for diff reports. Valid styles are C and C. The default is C. For commands that produce diff reports, this can be overriden with the C<--diff-style> option. This variable only has effect when using a local repository. =item C If set to 1, pinto will emit more diagnostic messages to STDERR. If set to 2, pinto will emit even more diagnostic messages. This variable only has effect when using a local repository. =item C Sets the timeout (in seconds) for obtaining a lock on the repository. The default is 50. This variable only has effect when using a local repository. =item C Sets the timeout (in seconds) to consider a lock on the repository stale and expire it. The default is 0 (don't expire). This variable only has effect when using a local repository. =item C Sets the path to the command pinto will use for interactive shells (like with the L command). If this is not set, pinto defaults to either C or C. =back =head1 SEE ALSO L to allow remote access to your Pinto repository. L for general information on using Pinto. L for hosting your Pinto repository in the cloud. =head1 AUTHOR Jeffrey Ryan Thalhammer =head1 COPYRIGHT AND LICENSE This software is copyright (c) 2015 by Jeffrey Ryan Thalhammer. This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. =cut