Advanced Rename Where Are You?

I cannot seem to find how to open Advanced Renamer. I know I've seen it before and maybe even used it. I may have whacked the button when I was trying to rebuild my computer but I cannot find any hot key or any alternate way to open it nor any method in the manual. The manual tells me how to use it but not how to get to it. I even started to create a button thinking it would be under commands but not there either. I thought maybe it would be a drop down off the Find tool which might be a nice alternative. But I'd just be glad to find it now. I could have manually retyped them at this point. Some of the confusion is there are a few different renames. There's the one that has the menu button where you have like prebuilt "scripts" for doing some more standard renames and then there's the rename on the context menu and then one of the Window's apps I use is called File Menu Tools it has a nice GUI Advanced Renamer. But none of these except maybe the first one would come close to doing what I need but I don't know how to find the instruction set for that one and the one that removed part of a name was actually a script that looked farily hard-coded so not sure it would be a good solution for me.

Maybe before you tell me how to get there you can tell me if this is possible in it. I have a screenful of filenames that all have data that I really don't care about following the file name within parens. I'd like to remove everything based on the " (" left-hand starting point to the ")" right-hand end point. Is that doable?

Related to this. Is there a way I could run a original untainted version of DO alongside my modified version, maybe in a VM? I've been using Virtual Box for a while. I don't use it often because I think it's tedious and problematic when trying to use or access hardware through it's extension pak. But maybe when I screw something up I could go back to that base to retrieve or restore a particular function.

Normally, you just select some files and click the Rename button.

If that opens the simple rename dialog instead, it's probably because this option in the button's menu has been turned on:

If so, click that option again to turn it off.

@disablenosel
Rename ADVANCED
@nodeselect

Regex & Replace rename:

  • Existing : \([^\)]*\)
  • New: leave it empty

I think VM are authorized. Otherwise, if you run a Pro version of windows and it's occasional, you can also use the Windows Sandbox, and install a version of Opus just for the time you get to check what you need to.

EDIT:
Regexp explanation:

  • \( : Start with a parenthese
  • [^\)] : Everything but a closing parenthese
  • *: any number of time (including 0)
  • \): end with closing parenthese

Since it's regexp and replace, all pattern matching that sequence in the filename will be replaced by nothing.

If only life were so simple lol. Here's an example of what I started wuth:

Test 1 (1080p_25fps_H264-128kbit_AAC)
Test 2 (128kbit_AAC)
Test 3 (Official Video) [4K] (128kbit_AAC)
Test 4 (10 Minutes Version) (128kbit_AAC)

and here are the results:

Test 1 this has 1 extra space at the end before the "." because I need to account for the space before the opening "(". It was in the initial question but may not have been obvious or maybe you thought it was a typo.
Test 2 same as #1. All of them have have this problem.
Test 3 [4K] This is an unusual name but it does happen. Can we remove the [4k] which may not always be at the same place in the name? There are also cases with garbage after the closing ")" so get rid of all the stuff from the closing paren ")" up to the "." but only after the last closing paren. Also note there is an extra space before the [4k] that needs to go. I'm not sure what generated that.
Test 4 This one has 2 spaces after the new name and before the period.

After the initial rename which I hadn't realized was adding spaces because of the way the New Name (or old for that matter) is displayed on it's own with no extension in the Rename GUI (someone may want to rethink that for the GUI) I thought all of them had 2 spaces prior to the ".", based on the results not in the GUI but in the lister, so I did a " " 2 for "" none rename but still a space remained. I didn't check the entire listing because it seemed like each had that third space before the "." and stupidly I did a rename " " 1 to "" none, not thinking about any needed spaces in the name, and oops they were gone. I didn't realize you could save the old names prior to the rename on the clipboard. It would be real nice to have an undo here. Also, why is there no minimize? I wanted to look at the original filenames at one point but there's no way to just minimize the rename GUI. Same with the synchronize function once you do the compare you are stuck with that little box overlaying your display that won't allow you to change files to process before the synchronize which is kind of weird like ;if you wanted to remove a delete or add a file to force sync, etc.

If you'd like I can write these up as suggestions or bugs or you can forward them to whoever as is

Anyway I'm not sure why I had 3 spaces. Unless I copied it incorrectly. You cannot cut and paste this or at least it wouldn't copy correctly for me which may be my clipboard processor. It seemed to be the "" escapes that didn't copy. It took me a bit to figure why I wasn't getting what I expected and then I realized the esacpes hadn't copied so I typed it by hand. I may have typed it wrong but I saved it and reused the saved one to process the test cases and got different spaces as I listed above. Weird but I can't say why the different answers. The test cases are the same names as I did initially just not as many.

In your explanation of the coding I get everything but the 2nd line. The bracket's deliniate that it's a group. The ^ menas not a closing paren ")" but why did you need this line. Why not just the first "(" to the last ")"? What would the difference be if I left this out?

What can make life easier sometimes could be shorter and more concise posts :slight_smile:

I don't have much time right now, so short answer below, maybe some more details later.
Put all this in a button, this should do the trick:

@nodeselect
Rename FINDREP REGEXP PATTERN="\([^\)]*\)" TO="" IGNOREEXT
Rename FINDREP REGEXP PATTERN="\[[^\])]*\]" TO="" IGNOREEXT
Rename FINDREP REGEXP PATTERN=" [ ]+" TO=" " IGNOREEXT
Rename FINDREP REGEXP PATTERN=" $" TO="" IGNOREEXT

First line eliminates groups of parentheses and everything in between.
Second line does the same for brackets.
Third line eliminates every redudant spaces (any number of spaces into a single one).
Fourth and last eliminates any trailing space at the end.

As promised, some more detailed info to answer your post:

Remaining spaces

Since the regexp is only removing parentheses and what's inside of them, if there was a space before and/or one after, the space(s) remain.
So a name like "Some Name (garbage).ext" turns into "Some Name .ext"

if you applied on Test 3 (Official Video) [4K] (128kbit_AAC): parentheses removal will get you the space after Test 3, and brackets removal wiil get you the two before and after [4K]

Solutions: either take into consideration the space before to remove it (regexp starts with \s* or \s to remove mutliple or single space), or, as I did, process name afterwards in a second substitution to remove redudant spaces and trailing space.

For the fact that it was in the original question, I did not see it (see my first comment of previous post ...)

Brackets

I did not see that in the initial request. Solution is to deal with them the same way we did for the parentheses.

Mass renaming updates / Undo

Not much to say except that this is one of the usefull part of the preview in the advanced rename.

CTRL+z works here to cancel a rename (even multiple files).

The preview pane gives you original and target names

Off-topic sync

I don't use that very often, but as far as I rememeber, I could uncheck sync propositions both in source (to not copy) and in destination (to not delete) before launching sync operation.

Coding explanation

Not really. They are defining a group of allowed characters.
Since inside the brackets, it starts with ^, it becomes forbidden characters.

If we did \(.*\), it would suppress everything between the first opening parenthese and the last closing one.

The difference could be seen on a file name such as: "My Video (some garbage) more info (some more garbage).ext".

First solution renames into: "My Video more info .ext"
Second solution renames into: "My Video .ext"

1 Like

Reminder: