Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Re: Persistent environment (Windows)

by idnopheq (Chaplain)
on Apr 10, 2001 at 16:49 UTC ( #71317=note: print w/replies, xml ) Need Help??


in reply to Re: Persistent environment (Windows)
in thread Persistent environment (Windows)

This is correct. The line
system("set monkeylikes=flinging poo");
sets %monkeylikes% for that system call only. You would need Win32::AdminMisc to set the variable permanently, or do
$ENV{'MonkeyLikes'} = "bananas"; print "$ENV{'MonkeyLikes'}\n"; system("echo %monkeylikes%"); $ENV{'MonkeyLikes'} = "flinging poo"; system("echo %monkeylikes%");
for on-the-fly while-the-script-executes kind-of stuff. It yields

bananas
bananas
flinging poo

I believe from the parent post that this is what you are looking for, but that is just my opinion. I could be wrong.

HTH
Dex

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://71317]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (5)
As of 2022-08-09 16:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?