Mailing List Archive

Feature request: scp not overwriting existing files
Hi,

I would like to have an option to have scp refrain from overwriting
target files if they already exist. Default behavior needs to be
unchanged to maintain compatibility, but an option to stop scp from
clobbering existing files would definetely be nice. If a file cannot
be written, scp should have another option to continue with the next
file instead of aborting.

Greetings
Marc

--
-------------------------------------- !! No courtesy copies, please !! -----
Marc Haber | " Questions are the | Mailadresse im Header
Karlsruhe, Germany | Beginning of Wisdom " | Fon: *49 721 966 32 15
Nordisch by Nature | Lt. Worf, TNG "Rightful Heir" | Fax: *49 721 966 31 29
Re: Feature request: scp not overwriting existing files [ In reply to ]
>I would like to have an option to have scp refrain from overwriting
>target files if they already exist. Default behavior needs to be

I agree, this would be useful.

As a workaround, you can run rsync on top of ssh instead of using scp.
rsync has all sorts of useful options, including --update, which inhibits
overwriting of newer files with the same name, and --backup, which
makes backup copies of overwritten files.

Phil
Re: Feature request: scp not overwriting existing files [ In reply to ]
On Mon, May 01, 2000 at 08:54:36PM +0000, Marc Haber wrote:
> On Sun, 30 Apr 2000 15:16:01 -0700, you wrote:
> >As a workaround, you can run rsync on top of ssh instead of using scp.
>
> That'd require an rsyncd on the remote host. Never touch a running
> system ;-)

it does not require rsyncd, just a rsync binary somewhere on the remote host.
Re: Feature request: scp not overwriting existing files [ In reply to ]
On Sun, 30 Apr 2000 15:16:01 -0700, you wrote:
>As a workaround, you can run rsync on top of ssh instead of using scp.

That'd require an rsyncd on the remote host. Never touch a running
system ;-)

Greetings
Marc

--
-------------------------------------- !! No courtesy copies, please !! -----
Marc Haber | " Questions are the | Mailadresse im Header
Karlsruhe, Germany | Beginning of Wisdom " | Fon: *49 721 966 32 15
Nordisch by Nature | Lt. Worf, TNG "Rightful Heir" | Fax: *49 721 966 31 29