Batch Renamer v2.0
This location is for Registered Users Only.
Perhaps you need to login or register.
Contributor: Tyler Lockard
With a simple UI, we can batch rename in Nuke. I'll also update your Read node for you!
Requirements:
10.0, 9.0, 8.0, 7.1, 7.0, 6.3, 6.2, 6.1, 6.0 or later
Linux, Mac, Windows
10.0, 9.0, 8.0, 7.1, 7.0, 6.3, 6.2, 6.1, 6.0 or later
Linux, Mac, Windows
07 Jun 2016
816
'Batch Renamer' removes all the hassle from jumping out of nuke, launching a batch rename program, probably messing up a few times, jumping back into Nuke and updating your read node... That takes like, a whole minute. That's just too long. With a simple UI we can do all that in Nuke, complete with highlight previews. I'll also update your Read node for you!
Recently updated to support multi-selections! Simply select a couple of read nodes. The rename operation will search-and-replace across every filename.
Comments? Questions? Feel free to reach out!
// Tyler Lockard // 2016 // tylerlockard.com //
Please login in order to download these files.
Comments
menubar = nuke.menu("Nodes")
m = menubar.addMenu ("Some Cool Stuff")
m.addCommand('Batch Rename', 'import batchrenamer; batchrenamer.main()')
Relaunch Nuke and there should be a menu with a command that pops the dialog open. Let me know if you're still having trouble.
Works for me but only for one node even if I selected a bunch of read nodes.
Any explanation?
Thanks
I just designed it to work on a single node unfortunately, but I could definitely look into expanding that.
Give me a couple days and I'll see what I can come up with, between work hours :)
I just want to add something.
I had to add another line of script because when I run the script it was giving error on the read node. I realized it was changing the first slash to a backslash. I believe it's a windows conversion issue.
So just after this line:
# We're done! Now let's punch in the new value on the respective node
I added this line:
dir = dir.replace('\\ ', '/')
Maybe you can add an IF statement so this line applies on windows operating systems.
Ahh pesky Windows file paths. That's the one OS that I can't properly test on, thanks a bunch for that call out!
I'll play around and include that in my next update.
[Error 32] The process cannot access the file because it is being used by another process.
Is there anyway around it?
That can be a fairly common error on some filesystems. If the files are being used in another app, some computer setups have issues with deleting or modifying them until they're no longer in use. I haven't run into that error using the renamer yet, but here's my best guess.
Try closing any applications that might be using the files. Think Quicktime Player, RV, Final Cut etc. (It's not typical, but sometimes even the "preview" function of some file browsers, depending on what operating system you're on.) Nuke by itself should be fine, but rendering in the background could cause it too, if it's using those files in the render.
Worst case scenario, you may have a "stuck" process that's holding onto those files, so to speak. I always hate doing it, but if all else fails, you could try the ol' "turn the computer off and on again" trick. That at least would guarantee that nothing's using the files when you reopen Nuke.
Lemme know how you make out. It can be tricky to troubleshoot without being on your computer.
RSS feed for comments to this post