Env export in perl

M

Murugesh

HI,
I could not export Environmental varibles into the shell from a
perl script.
This is wat I have tried,

$ENV{PATH}="\/usr\/local\/bin:$ENV{PATH}";

Inside the program, when I print PATH, it is shown correctly.But, when
the program exits, the value of PATH expires and retains the old value.
How can we make it to retain the value, even after the program exits.
I ran the script in solaris .
Thanks in advance.
 
A

A. Sinan Unur

$ENV{PATH}="\/usr\/local\/bin:$ENV{PATH}";

Inside the program, when I print PATH, it is shown correctly.But, when
the program exits, the value of PATH expires and retains the old value.
How can we make it to retain the value, even after the program exits.

perldoc -q environment

You are supposed to check the FAQ before posting here.
Thanks in advance.

*Sigh*

Sinan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,770
Messages
2,569,584
Members
45,075
Latest member
MakersCBDBloodSupport

Latest Threads

Top