You have to set entries in the Windows registry to do this
permanently. I'm not in a position at the moment to be able to look up
the details, but perhaps just knowing this can lead you to finding the
answer.

Curt

On 8/15/06, Cameron, Gemma (UK) <gemma.cameron / baesystems.com> wrote:
>
> Hi Austin,
>
> Thanks for all that - but I think you missed the point. I need to set up the env path of the machine permanantly. Say we wanted to bring in a new build machine or the old one died/I spilled coffee on it... :s The point being that I want the environment variables on the machine, not in the shortcut/script/kernal I'm running. I have done something similar before using NSIS which worked great as lots of programs had to also be installed and programs placed in folders etc.
>
> And by thinking in ant - I'm new to ruby and with Ant I know there's pretty much nothing I can't do - it's mostly all been tasked before so I merely sent a few parameter through and what I want happens magically!
>
> I'm sure it'll be even easier with Ruby but I'm still finding my feet. ( :
>
> Thanks a lot for the input everyone, it's greatly appreciated! Especially such great information in such massive quantities and so quickly!!!
>
> Regards
>
> Gemma Cameron
> Senior Software Engineer
> Eurofighter ESS (SHM)
>
> tel: 01772 858492
>
>
> -----Original Message-----
> From: Austin Ziegler [mailto:halostatue / gmail.com]
> Sent: 15 August 2006 14:01
> To: ruby-talk ML
> Subject: Re: Setting Windows Environment Variables
>
>
>               *** WARNING ***
>
> This mail has originated outside your organization,
> either from an external partner or the Global Internet.
>     Keep this in mind if you answer this message.
>
> On 8/15/06, Lyndon Samson <lyndon.samson / gmail.com> wrote:
> > You might be in luck.
>
> Not really. You can't change the environment of an already running
> process that isn't yourself. Even if one were to go into the System
> control panel and change the environment variables, any shortcut
> launchers (as I often use) will themselves need to be relaunched to
> take advantage of the updated environment variables. Certainly, there
> must be a way to refresh the internal environment variable table based
> on the current registry settings, but that would be based on a global
> signal.
>
> I'm not sure what the OP's post about thinking in "ant" is, because
> Ant would be similarly limited. This is not a Ruby limitation; it is
> one of the few limitations that is essentially cross-platform and
> found on every platform in existence to the best of my knowledge. The
> only reason that shell script functions and DOS/Winodws batch files
> can affect the current level's environment variables is that they are
> not in a separate process and are therefore just modifying the current
> process's environment variables.
>
> -austin
> --
> Austin Ziegler * halostatue / gmail.com * http://www.halostatue.ca/
>               * austin / halostatue.ca * http://www.halostatue.ca/feed/
>               * austin / zieglers.ca
>
>
>
> ********************************************************************
> This email and any attachments are confidential to the intended
> recipient and may also be privileged. If you are not the intended
> recipient please delete it from your system and notify the sender.
> You should not copy it or use it for any purpose nor disclose or
> distribute its contents to any other person.
> ********************************************************************
>
>