View Full Version : Setting env variables
ndeboar 11-01-2010, 03:53 AM Hey,
I'm trying to set some environment variables before I run Nuke, eg:
env.bat:
setx NUKE_PATH c:\nuke\
start "Nuke" "C:\Program Files\Nuke6.0v2\Nuke6.0.exe"
But, they only get set when I close Nukeand reopen it.
What's the trick? I'ld like to keep it as bat script.
Cheers,
Nick d
|
|
UrbanFuturistic
11-03-2010, 07:22 PM
Why are you permasetting an environment variable every time you start Nuke and why aren't you doing this through the environment variable settings dialog?
ndeboar
11-04-2010, 02:46 AM
Well, that's the plan, this is just temp setup. Might fire up python a build something.
mje11even
11-04-2010, 06:04 AM
setx permanently sets/changes an environment variable, but the variable is only available in future command windows. If you just want to set the environment variable temporarily while running nuke, you probably want to use set, but then you may have to add a /wait parameter to start so that the environment variable stays set until you exit nuke. I didn't test this, but should be easy to check if it works.
env.bat:
set NUKE_PATH c:\nuke\
start /WAIT "Nuke" "C:\Program Files\Nuke6.0v2\Nuke6.0.exe"
noizFACTORY
11-05-2010, 05:37 AM
Or in you batch script:
NUKE_PATH=c:\nuke\
"C:\Program Files\Nuke6.0v2\Nuke6.0.exe"
CGTalk Moderation
11-05-2010, 05:37 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
vBulletin v3.0.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.