> ""kilaru" == "kilaru rajeev" <[EMAIL PROTECTED]> writes:
"kilaru> Can anybody help me to add a directory to @INC variable?
Since that's one of the many things that is answered in the FAQ,
I will repeat what I say from time to time...
if you're on this list, you should read "perldoc perlfaq
Beginner wrote:
On 21 Mar 2007 at 0:00, Jeff Pang wrote:
1)
use lib '/path/to/somedir';
2) unshift @INC, '/path/to/somedir';
This can't work when you add a path to @INC on runtime.
BEGIN {
unshift @INC,'/path/...';
}
Do you mean you have to put it in a BEGIN block to work?
Yes.
On 21 Mar 2007 at 0:00, Jeff Pang wrote:
>
> >
> >1)
> >use lib '/path/to/somedir';
> >
> >2) unshift @INC, '/path/to/somedir';
> >
>
> This can't work when you add a path to @INC on runtime.
>
> BEGIN {
> unshift @INC,'/path/...';
> }
Do you mean you have to put it in a BEGIN block to wo
Thank you for your help,
Rajeev Kilaru
On 3/21/07, Rob Dixon <[EMAIL PROTECTED]> wrote:
kilaru rajeev wrote:
>
> Hi,
>
> Can anybody help me to add a directory to @INC variable?
use lib '/my/dir';
Take a look at
perldoc lib
HTH,
Rob
kilaru rajeev wrote:
Hi,
Can anybody help me to add a directory to @INC variable?
use lib '/my/dir';
Take a look at
perldoc lib
HTH,
Rob
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
On 21 Mar 2007 at 17:05, kilaru rajeev wrote:
> Hi,
>
> Can anybody help me to add a directory to @INC variable?
>
> Thanks,
> Rajeev Kilaru
>
Either of these should work. Put them at the top, before you use
something from somedir.
1)
use lib '/path/to/somedir';
2) unshift @INC, '/path/to/
Hi,
Can anybody help me to add a directory to @INC variable?
Thanks,
Rajeev Kilaru