Nuke new wihtout spanning a new instance

Hi, I am trying to find a way to clear a nuke script (basically File – New) but I don’t want a new instance of Nuke to start.

I need this for scripting purpose. It is not really useful to span a new Nuke while in a script as the script doesn’t follow in the new instance (which makes sense).

I have a script that can take a list of shots and build pre-comp script. But At the moment I need to execute each shot separately because of this bug… which sucks a whole lot!

I have tried using the command
import nuke
nuke.scriptClear()

But this command seems to break Nuke! A bunch of commands fails after running this command (Even using the menu File – Clear will do this)

Example:
import nuke
# next command will work
print nuke.root().name()
# clear the script
nuke.scriptClear()
# Same command now fails
print nuke.root().name()

No Responses to “Nuke new wihtout spanning a new instance”

Post a Comment