We came across this question recently and aren't really certain how to answer it without some input from you all.
Currently when you create a new file in Nuke using the Shotgun File Manager (tk-multi-workfiles), we issue a call to
nuke.scriptClear(). This resets the current script (though I believe the layers and channels remain as they are stored globally in the session). We initially chose this method as it allows you to start from a clean blank slate while not requiring you to launch a new instance of Nuke, which would also require also initializing the engine and apps for that instance and would take several seconds to complete. So this way just felt cleaner and quicker than calling
But it doesn't run the default behavior of starting with a template loaded from
~/.nuke/template.nk. So if you have a need to start your new scripts from a template, you'd need to modify the tk-multi-workfiles SceneOperation hook for Nuke to load this file. And there may be other things we're not thinking about here.
We haven't heard much complaint over the way we're doing things now, but we're a little insecure :) so we wanted to reach out and ask if you think what we're doing is weird, or if it works well. We do this all in a hook, so of course you're welcome to customize it as needed though we'd like to provide the best use case as the default hook behavior, and then allow you to modify it for your specific needs from there.
So, any thoughts?