Welcome to Vifm Q&A, where you can ask questions about using Vifm. Registration is optional, anonymous posts are moderated. E-mail and GitHub logins are enabled.
0 votes
in vifm by

Hi everybody,

to rsync file or directory under the cursor to the other panel I try without any success the following command:

command rsyncCopy :execute '!rsync -av --delete %c $D/'

I think the issue is coming from %c because it's return only the name of the file under the cursor.

How can I get the full path ?

Thx

1 Answer

0 votes
by

Hi,

you keep trying to use :execute when it's unnecessary, the main issue is that $D should be %D:

command rsyncCopy rsync -av --delete %c %D/

A version with :execute should have doubled % to postpone expansion until :! is run:

command rsyncCopy :execute '!rsync -av --delete %%c %%D/'
by

both versions are top ! Thank you lovely <3

by

quite interesting, VIFM :copy is 40 % faster than rsync - tested with 40 GB

by

Does the word command need an exclamation mark ?

command rsyncCopy rsync -av --delete %c %D/

or

command! rsyncCopy rsync -av --delete %c %D/

by

It's optional and allows overwriting a previously defined command of the same name.

If you would like to make a bug report or feature request consider using GitHub, SourceForge or e-mail. Posting such things here is acceptable, but this is not a perfect place for them.
...