[TynesideLUG] Copying data between two Ubuntu systems

Ian Bruntlett ian.bruntlett at gmail.com
Tue Aug 25 09:46:49 UTC 2020


Hi All,

I recently came across some info about rsync that might be of interest and
I hope I am explaining it properly.

Imagine you have a directory of files, with at least one with the name
"--delete".

If you do
rsync -r * ~/destination

Then the bash shell will place all the filenames of the current directory
into the command - including the filename --delete which means "delete
extraneous files from dest dirs"

One way to mitigate this is to use the command

rsync -r -- * ~/destination

HTH,


Ian

-- 
-- ACCU - Professionalism in programming - http://www.accu.org
-- My writing - https://sites.google.com/site/ianbruntlett/
-- Free Software page -
https://sites.google.com/site/ianbruntlett/home/free-software


More information about the Tyneside mailing list