On Tue, 2008-10-07 at 12:36 +0100, Dermot wrote:
> Hi,
> 
> I have seen the following is a book
> 
> 
> use strict;
> use warnings;
> use FindBin qw($Bin);
> use Path::Class;
> use lib dir ($Bin,'..','lib')->stringify;
> 
> 
> An adopted it into a script of my own. I understand that this FindBin
> will allow the code to be ported between OS's. That's isn't massively
> important to my current script but i'd like to follow good practise
> and stick with it.
> 
> The bit that is confusing me is the use lib statement because I need
> to extend @INC and I don't know who to modify that lib statement to
> fit my other path in. Where does dir come from and what is this
> stringfy method?
> 
> TIA,
> Dp
> 

`dir` is from Path::Class, see `perldoc Path::Class` for details.  If
you release your code to the public be sure to add your non-standard
modules to the REQUIREMENTS section of the code's POD.


-- 
Just my 0.00000002 million dollars worth,
  Shawn

Linux is obsolete.
-- Andrew Tanenbaum


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to