Scp + Avoid copying if the same filename is on the remote computer?
Is it possible to specify the scp command - do not copy the file from the current computer to the case file on the remote computer.
for example
On my machine, I have a file -
/etc/secret-pw.txt
On a remote machine, I have a file -
/etc/secret-pw.txt
So,
scp /etc/secret-pw.txt $remote_machine:/etc
Will destroy secret-pw.txt and scp won't ask questions about: overwrite target file
Is there an option to avoid copying if the file exists on the target machine using scp?
Update: I can't install rsync or any other program.
+3
source to share
2 answers