From: apeiron Date: Fri, 10 Apr 2009 02:21:20 +0000 (+0000) Subject: Better docs and nix the .svn files from being included in the dist. X-Git-Tag: 1.006009~81 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=480e6e8501e05e94f27dbf839dfdf80e6e70a1f7;p=p5sagit%2Flocal-lib.git Better docs and nix the .svn files from being included in the dist. git-svn-id: http://dev.catalyst.perl.org/repos/bast/local-lib/1.000/trunk@5882 bd8105ee-0ff8-0310-8827-fb3f25b6796d --- diff --git a/Changes b/Changes index 8c0d7e8..b16e1bc 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,9 @@ Revision history for local::lib +1.003003 2009-04-09 + - Expose the internals per RT #36846. + - Fix the MANIFEST up a bit. + 1.003002 2009-02-25 - Add a doc patch from Torsten Raudssus that clarifies how to specify a directory other than ~/perl5. diff --git a/MANIFEST.SKIP b/MANIFEST.SKIP index 3e3f5be..bdad680 100644 --- a/MANIFEST.SKIP +++ b/MANIFEST.SKIP @@ -1 +1,2 @@ ^(?!script/|examples/|lib/|inc/|t/|Makefile.PL$|README$|MANIFEST$|Changes$|META.yml$) +.svn diff --git a/lib/local/lib.pm b/lib/local/lib.pm index b4a3841..160ff33 100644 --- a/lib/local/lib.pm +++ b/lib/local/lib.pm @@ -11,7 +11,7 @@ use File::Path (); use Carp (); use Config; -our $VERSION = '1.003002'; # 1.3.2 +our $VERSION = '1.003003'; # 1.3.3 sub import { my ($class, @args) = @_; @@ -402,6 +402,138 @@ PATH is appended to, rather than clobbered. These values are then available for reference by any code after import. +=head1 METHODS + +=head2 ensure_directory_structure_for + +=over 4 + +=item Arguments: path + +=back + +Attempts to create the given path, and all required parent directories. Throws +an exception on failure. + +=head2 print_environment_vars_for + +=over 4 + +=item Arguments: path + +=back + +Prints to standard output the variables listed above, properly set to use the +given path as the base directory. + +=head2 setup_env_hash_for + +=over 4 + +=item Arguments: path + +=back + +Constructs the C<%ENV> keys for the given path, by calling +C. + +=head2 install_base_perl_path + +=over 4 + +=item Arguments: path + +=back + +Returns a path describing where to install the Perl modules for this local +library installation. Appends the directories C and C to the given +path. + +=head2 install_base_arch_path + +=over 4 + +=item Arguments: path + +=back + +Returns a path describing where to install the architecture-specific Perl +modules for this local library installation. Based on the +L method's return value, and appends the value of +C<$Config{archname}>. + +=head2 install_base_bin_path + +=over 4 + +=item Arguments: path + +=back + +Returns a path describing where to install the executable programs for this +local library installation. Based on the L method's +return value, and appends the directory C. + +=head2 modulebuildrc_path + +=over 4 + +=item Arguments: path + +=back + +Returns a path describing where to install the C<.modulebuildrc> file, based on +the given path. + +=head2 resolve_empty_path + +=over 4 + +=item Arguments: path + +=back + +Builds and returns the base path into which to set up the local module +installation. Defaults to C<~/perl5>. + +=head2 resolve_home_path + +=over 4 + +=item Arguments: path + +=back + +Attempts to find the user's home directory. If installed, uses C +for this purpose. If no definite answer is available, throws an exception. + +=head2 resolve_relative_path + +=over 4 + +=item Arguments: path + +=back + +Translates the given path into an absolute path. + +=head2 resolve_path + +=over 4 + +=item Arguments: path + +=back + +Calls the following in a pipeline, passing the result from the previous to the +next, in an attempt to find where to configure the environment for a local +library installation: L, L, +L. Passes the given path argument to +L which then returns a result that is passed to +L, which then has its result passed to +L. The result of this final call is returned from +L. + =head1 A WARNING ABOUT UNINST=1 Be careful about using local::lib in combination with "make install UNINST=1".