Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: ENV INFORMATION

by robartes (Priest)
on May 21, 2005 at 12:08 UTC ( #459235=note: print w/replies, xml ) Need Help??


in reply to ENV INFORMATION

I'm afraid you cannot influence your parent's environment from inside the Perl script, and certainly not by setting %ENV keys. Those variables only get propagated 'downwards' in the process tree, towards children of your perl script, not upwards towards the parent.

As phaylon mentioned, perldoc -q environment describes a hack whereby you output the VAR=value commands from your script and pull that through the shell's eval function, but then you're no longer inside your perl script. And it might not work with all shells either.

CU
Robartes-

Replies are listed 'Best First'.
Re^2: ENV INFORMATION
by schwern (Scribe) on May 23, 2005 at 10:43 UTC
    I'm afraid you cannot influence your parent's environment from inside the Perl script

    ...unless you happen to be running VMS.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://459235]
help
Chatterbox?
[Your Mother]: Hey, let's not bring antisemitism into the conversation.
[LanX]: for centuries posh English speakers tried to approach French, that's where all the trouble starts
[Eily]: Just another Perl coeurs
[Eily]: (perl with hearts, 'Acker with a French accent is pronunced like coeurs)
[LanX]: IMHO 'ju' for 'u' happens in English where they can't pronounce the French u (or German )
[LanX]: and I'm sure I read that *hotel* used to be pronounced 'otel by the English upperclass
[Your Mother]: American English vowels are pretty lazy/mumbly in general.
[LanX]: talking about antisemitism, youtube automatic subtitles is entertaining shocking sometimes ... like when offering "Fruit Jews" as a drink
[Your Mother]: ...Come on you King of the Juice...
[Your Mother]: I actually know his kids.

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (10)
As of 2017-03-27 17:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (320 votes). Check out past polls.