Prefer -u not to change newer files.

Matt McCutchen matt at mattmccutchen.net
Sun Jan 27 10:58:19 GMT 2008


On Sun, 2008-01-27 at 02:22 +0100, Donald Axel wrote:
>     Quoting man page:
> 
>               In  the  currently implementation, a difference of file format is
>               always considered to be important enough for an update, no matter
>               what date is on the objects.  In other words, if the source has a
>               directory or a symlink where the  destination  has  a  file,  the
>               transfer  would  occur  regardless of the timestamps.  This might
>               change in the future (feel free to comment on this on the mailing
>               list if you have an opinion).
> 
>    Comment: -u should preferably mean "update" only if target is older.
> 
> 
>    Actually I found out by experimenting that rsync may overwrite
> anything different at the target. 
> 
>    Using the -u option as "only if newer" would be analogous with zip,
> unzip and cp and probably many other program.

OK...could you give us a concrete example in which it is helpful to have
the straight "only if newer" behavior instead of the current one?

Matt



More information about the rsync mailing list