Topic "custom command for duplicating files"

Author Message
FoTo50
[View user's profile]

Joined: 2011-10-09
Posts: 1
Location: Austria
Hi all,

many times, I need to copy remote files with the attributes " -r --no-preserve=mode,ownership" to keep the target ownership and rights in case it exists. The default duplicate command does not provide these so I tried to create some custom command in WinSCP like:

cp -r --no-preserve=mode,ownership ! !?Target:?!/!

Target I wanted to fill with the current path by default, but obviously, this fails here as this is also the char for the prompt ending. How do I create this custom command correct?

I also first tried to "!&" instead of ! for the source to be able to copy multiple files, but then got that error "cannot combine ..."??

Any help would be very much appreciated
Greetz
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25034
Location: Prague, Czechia
Thanks for your post.
This has been added to the tracker:
https://winscp.net/tracker/show_bug.cgi?id=743
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License