I want to use the contents of the clipboard to rename a file using the rename internal command.
So I tried this: rename PATTERN "(.*)(\.*)" TO "clipboard paste \2" REGEXP
Should that work?
The closest I find when I search is an apparent attempt to do the same with the DO internal command but I am not sure if I am reading that post correctly.
(You can also access it from scripts if you want to do extra checks to make sure it's the right type of data, or extra processing on what's in the clipboard before sending it to the command. Opus provides methods to both get and set the clipboard.)
I am runniing that with one file highlighted from the CLI prompt >
I am expecting the file to be renamed to XXXXXX.ext because I have XXXXXX in the clipboard at the time of execution.
When I execute the command above the Rename dialog is bought up
Any ideas...?
I am often wanting to rename a file with the contents of the clipboard.
So I am only interested in a single file.
The rename command above is indeed only suitable for one file
My thanks once more