> "Jeff" == Jeff 'japhy' Pinyan <[EMAIL PROTECTED]> writes:
>> I don't believe @ARGV is set up early enough to do that. I'd be happy
>> if that worked, but I'm suspicious. Have you tested this?
Jeff> japhy% bleadperl -le 'BEGIN { print "<@ARGV>" }' a b c
Jeff>
I sit corrected. :)
-
On Feb 5, Randal L. Schwartz said:
>> "Jeff" == Jeff 'Japhy' Pinyan <[EMAIL PROTECTED]> writes:
>
>Jeff> use lib $ARGV[0] eq '-foo' ? "/this/path" : "/that/path";
>
>I don't believe @ARGV is set up early enough to do that. I'd be happy
>if that worked, but I'm suspicious. Have you tested
On Tue, 5 Feb 2002, Kingsbury, Michael wrote:
> I want to have two different variable for use lib depending on a cmd line
> switch (one for the production libraries, one for development libraries).
> They exist in different directories. It appears that it uses the use lib at
> compilation time,
> "Jeff" == Jeff 'Japhy' Pinyan <[EMAIL PROTECTED]> writes:
Jeff> use lib $ARGV[0] eq '-foo' ? "/this/path" : "/that/path";
I don't believe @ARGV is set up early enough to do that. I'd be happy
if that worked, but I'm suspicious. Have you tested this?
--
Randal L. Schwartz - Stonehenge
On Feb 5, Kingsbury, Michael said:
>I want to have two different variable for use lib depending on a cmd line
>switch (one for the production libraries, one for development libraries).
>They exist in different directories. It appears that it uses the use lib at
>compilation time, rendering an if
> -Original Message-
> From: Kingsbury, Michael [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, February 05, 2002 11:31 AM
> To: '[EMAIL PROTECTED]'
> Subject: use lib question
>
>
> I want to have two different variable for use lib depending
>
use BEGIN:
perl -e 'BEGIN {if (`pwd` =~ /some_path/){use lib ("/usr");}else{use lib
("/home");}}'
i usually unshift @INC but i've heard that's not a good way to do it,
not sure why though.
/Jon
"Kingsbury, Michael" wrote:
>
> I want to have two different variable for use lib depending on a cm
I want to have two different variable for use lib depending on a cmd line
switch (one for the production libraries, one for development libraries).
They exist in different directories. It appears that it uses the use lib at
compilation time, rendering an if statement useless. Anyone have a slick