Copy and paste into source folder

Hi!

I bet, I've read this somewhere in forums, however, I did not find the posting anymore.

When copying (ctrl+c) a file from a folder and press ctrl+v, DO copies the file into the root instead of the origin folder. I explicitly have to select the source folder to get the file pasted there.

I'm talking about the new feature of expandable folders in DO, btw, see pic below.

In the example below, I would like to copy the file at (1) and paste it again into the same source folder "Eingabe". However, pressing ctrl+v copies the file at (2).

When selecting "Eingabe" first and pressing ctrl+v, the file gets copied to this folder.

The current command for pasting files is

Clipboard PASTE 

What's the correct argument to the command above to achieve pasting into source folder again?

You are probably looking for

Clipboard PASTE USESEL

Thanks Alex!

Now, that I've found some time for using this command, I noticed it's not working as expected. When modifying the command as above, each copy&paste action does not work anymore.

To be precise: I press ctrl+c on one file and opening a different target folder other than the source, ctrl+v does nothing. Reverting back to the original command (w/o USESEL) works again.

At the end this means, copy and paste as described above is not yet solved.

My current workaround is to hold the ctrl key and drag&drop the file to be copied into the destination folder.

I see... you want to quickly create a copy with Ctrl-C/V without changing the selection, right?

Try

Clipboard PASTE COPYCOMMANDARGS="TO=""{filepath|..}"""

You could also do it like this:

@ifsel:!numfiles=0,numdirs=1
Clipboard PASTE
@ifsel:else
Clipboard PASTE USESEL

This won't work with files in expanded folders, I am afraid.

Ah, I missed that it needed to paste into the selected file's parent folder if a file rather than a folder is selected. (Bit weird IMO.)

Yeah, but this is how Windows Explorer works if you do not switch to a different target folder.

Copy&paste within the same folder copies the file(s) into the same folder ^^ and if you are lucky :wink: it will rename existing files.

This works perfectly - thanks for this!

How can it? File Explorer doesn't have expandable folders.

Of course Explorer does not have this nice feature.

I meant when copy and pasting in the very same folder, you are currently in, Windows simply performs that action, including renaming by adding a (1), e.g.

So does Opus.

The folder you are in is the one shown in the path field. If you expand sub-folders, that doesn't change what the current folder is (and it'd be chaos if it did :)).

(Being able to copy/move things from sub-folders up to the main folder is also really useful and common, at least in my experience.)