Please can you extend COPYNAMES with a parameter to get forward slashes instead of back slashes?
It's recommended to use e.g. "C:/MyDir/MySubdir" in e.g. Markdown documentation and many other software (e.g. R, Perl, etc.) incl. Windows cmd.exe itself supports "/" .. e.g. "cd /MyDir/MySubdir" works.
How do I add a forward slash to the end?
I tried several things. Or the function doesn't work anymore or it adds multiple slashes.
For example a path with 5 backward slashes adds ///// to the end.
That's because the pattern has a # on the end, which tells Opus to keep re-applying the regex until the string stops changing (or until it starts looping). So if you add the extra slash as part of the same pattern, you'll add one slash to the end for every backslash that the pattern replaces.
To add just a single slash, while still converting backslashes to slashes, use a second, separate pattern to add it, like this:
Note that this will add the extra slash indiscriminately, even if the thing in the clipboard is a file path not a folder. You could add a modifier to make the button ignore files, or make it disabled if files are selected. Or you could use scripting to make the extra slash conditional on the type of item, if needed.