Move different words to desired position

Advanced Renamer forum
#1 : 16/01-19 14:47
Javi
Javi
Posts: 1
Hi everyone, I'm new around here though I've been using Advanced Renamer for a while. Great tool!

I work with image sequences and usually manage pretty well to rename files, but today I got this problem I cannot solve (and I got lots of frames to work with)


I have a folder with this files structured like this:

BOB02_470_diffuse_direct_v001.1001.exr
BOB02_470_diffuse_direct_v001.1001_back.exr
BOB02_470_diffuse_direct_v001.1001_front.exr
BOB02_470_diffuse_direct_v001.1001_left.exr
BOB02_470_diffuse_direct_v001.1001_right.exr
BOB02_470_diffuse_direct_v001.1001_top.exr
-
BOB02_470_diffuse_direct_v001.1002.exr
BOB02_470_diffuse_direct_v001.1002_back.exr

.... and so on


I need to move the words <_back>, <_front>, <_left>, <_right> and <_top> to get in position just after <direct>

So my file names would stay like this:
BOB02_470_diffuse_direct_back_v001.1001.exr


I have tried with the Move tool, using tags to identify these words and move them where I want, but I am uncapable as I don't fully understand the way the tags work.

I could move the files into separate folders per word, but the amount of frames is so huge this would take me a long time.

Maybe you guys can find out the fastest way to do this.
Thanks in Advance :P


16/01-19 14:47
#2 : 17/01-19 03:54
L B
L B
Posts: 74
Reply to #1:

You can achieve this easily using Replace tool and RegEx:

Text to Be Replaced : (.*_direct)_(.*\d)_(.*)
Replace WIth : \1_\3_\2

Make sure "Use Regular Expressions" tick box is checked.

Alternatively, if the version information is always going to be present but the text prior to it keeps changing, you can try this:


Text to Be Replaced : (.*)_(v.*\d)_(.*)
Replace WIth : \1_\3_\2


17/01-19 03:54 - edited 17/01-19 10:38