Hello! I have a toolbar button script which removes “ - YouTube” from the end of any file downloaded from YouTube. For example, a downloaded video's file name is:
To remove “ - YouTube” from the above file's name, I press a hotkey which runs the following command:
Rename FINDREP PATTERN=" - YouTube" TO=""
The problem I've run into is, Directory Opus makes temporary copies of those files first, then Directory Opus performs the renaming function (it removes - YouTube from the file names). This is a problem when the files are very large, as many YouTube videos typically are many MB to GB in size.
••• Question 1: Why does Directory Opus make temporary copies of the selected files first, then rename the files, rather than just renaming the files without the copying part? I realize Directory Opus has to determine if there are going to be name conflicts before renaming files, but why the temporary copies?
••• Question 2: Is there a different script command that performs the same renaming function as Rename FINDREP PATTERN=" - YouTube" TO="" without having Directory Opus create temporary copies first?
I'm guessing it's possible there might be commands that clash with others. Maybe I should break up the commands and assign them to different toolbar buttons?
Using a rename script would be better, if you want to combine all of those into one operation. Then you generate the right name for each file and rename it once, instead of potentially renaming it many times.
You can also use wildcards or regular expressions to combine several of the lines and handle more cases; e.g. by matching any number in brackets or square brackets instead of just 20 specific numbers.