Nuke Tips – Reveal in Explorer

nuke_revexplorer_header

Fast and Furious way to revealing the revelations

One of the oddest thing in Nuke is the lack of a way to reveal the directory of a read/write node in Windows Explorer (or the OS native file browser like Mac OSX Finder).

I managed to find this script at Nukepedia that works like a charm.

All credit goes to Saurabh Sameer for the script!

def Revealexplr():
     import os
     a=nuke.selectedNode()
     b=a['file'].value()
     u=os.path.split(b)[0]
     u = os.path.normpath(u)
     print u
     cmd = 'explorer "%s"' % (u)
     print cmd
     os.system(cmd)

mymenu=nuke.toolbar('Nodes',)
mymenu.addCommand('RevealInExplorer','Revealexplr()')

Copy the above code into menu.py (located in the plugins folder) and use the Tab function in the node graph to call out RevealInExplorer to execute it at the read/write node of your choice.

You can refer to the header image if you need reference on where to put the script in the menu.py. I put it right before the # Menu definitions since it is situated at the top of the menu.py script.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.