LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   Rsync - Only copy files that do not exist at the destination directory? (http://www.linuxquestions.org/questions/linux-software-2/rsync-only-copy-files-that-do-not-exist-at-the-destination-directory-4175441883/)

wh33t 12-17-2012 07:33 PM

Rsync - Only copy files that do not exist at the destination directory?
 
Hey LQ,

I can't seem to figure out what combination of switches will get Rsync to only copy files from a source dir to a destination dir if that file DOES NOT exist at the destination. In other words I do not want to overwrite any files on the destination, even if they are older.

Any ideas?

jarro_2783 12-17-2012 10:25 PM

use --ignore-existing

wh33t 12-17-2012 10:56 PM

Of course! Thank you

pouldney 03-02-2014 05:30 PM

cp (copy command) is a better command to do what you want

sudo cp -vn /xxx/* /yyy

xxx = from directory
yyy = to directory

-vn = verbose , no clobber


All times are GMT -5. The time now is 05:14 AM.