Hi dear developers!
I'm not sure if this has even been up before, but anyways, just out of curiosity, would it be possible to make the "Search & Replace" section in our beloved CTRL+M (Multi Rename Tool) to allow more than one expression? Say I want to replace "a" with "b" and "x" with "y", respectively. Right now I use the tool two times in a row, one with each string.
I tried using the first non-accepted-in-filenames-anyways-character that I could think of for a "delimiter", namely the semicolon, so I wrote "a;x" in the Search for field and "b;y" in the Replace field with field, and held my fingers crossed. Nah, it didn't work. In most cases, I guess I could make a pretty complex RegEx line for a one-click chain, but say for simple renaming procedures not even involving regular expressions, wouldn't it be pretty neat if you could chain it kind of the way I suggested?
Assuming it wouldn't somehow "nestle" the renaming process (and therefor not is featured) I'm guessing the implementation would be fairly easy?
Cheers!
Multiple expressions in Multi-Rename Tool
Moderators: white, Hacker, petermad, Stefan2
Re: Multiple expressions in Multi-Rename Tool
- open MRT
- press F1
- read
That
- press F1
- read
Works only for plain text, so don't enable RegEx!Search & Replace
The string entered in the field 'Search for' ... . . . . .
. . . .
.. .. . .
You can search+replace multiple strings in one step! The strings need to be separated by the vertical line (Alt+124).
Example: Replace Umlauts+Accents:
Search for: ä|ö|ü|é|è|ê|à
Replace with: ae|oe|ue|e|e|e|a
That
Re: Multiple expressions in Multi-Rename Tool
Hahahaha EXACTLY what I was looking for the whole time!
Funny by the way, in my attempts, since semicolon didn't work, I thought "Hmm, this seemingly basic feature SHOULD already be in TC, so what could the dividing character be if not semicolon..." and the next time that came to my head was the vertical line, so I actually tried it, but it still didn't work.
As it turned out, my last MRT task was a RegEx one, so I had the RegEx checkbox selected (I rarely uncheck it, since it mostly doesn't collide with / mess up basic Search & Replace jobs), which of course makes the "|" be interpreted in the wrong way, and this was why it didn't work.
Thanks anyways, much appreciated!
Funny by the way, in my attempts, since semicolon didn't work, I thought "Hmm, this seemingly basic feature SHOULD already be in TC, so what could the dividing character be if not semicolon..." and the next time that came to my head was the vertical line, so I actually tried it, but it still didn't work.
As it turned out, my last MRT task was a RegEx one, so I had the RegEx checkbox selected (I rarely uncheck it, since it mostly doesn't collide with / mess up basic Search & Replace jobs), which of course makes the "|" be interpreted in the wrong way, and this was why it didn't work.
Thanks anyways, much appreciated!
- ghisler(Author)
- Site Admin
- Posts: 48077
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Re: Multiple expressions in Multi-Rename Tool
Semicolons aren't used here because they are valid characters for file names. The pipe symbol | cannot appear in file names, so it's used to separate multiple options.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com