On Wed, 8 Aug 2001, Matt Crapo wrote:

> I have not figured out how to change the perl library path in my
> environment.  Would love to know how if anybody can advise.  I have,
> however, figured out how to include it in a script.

PERL5LIB=$PERL5LIB:/path/to/module
export PERL5LIB

(assuming you are using a Unixish system)

> A script will process any "use" or "require" statements first, so in
> order to change something that affects those, you have to do it in a
> BEGIN block which will always execute first.  For example:

You can also do

use lib '/path/to/module';

use Module;

No need to mess around with the BEGIN block.

-- Brett
                                   http://www.chapelperilous.net/btfwk/
------------------------------------------------------------------------
It's gonna be alright,
It's almost midnight,
And I've got two more bottles of wine.


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to