@opindex --update
@cindex newer files, copying only
Do not copy a non-directory that has an existing destination with the
-same or newer modification timestamp; silently fail instead.
-If timestamps are being preserved,
+same or newer modification timestamp; instead, silently skip the file
+without failing. If timestamps are being preserved,
the comparison is to the source timestamp truncated to the
resolutions of the destination file system and of the system calls
used to update timestamps; this avoids duplicate work if several
@opindex --update
@cindex newer files, moving only
Do not move a non-directory that has an existing destination with the
-same or newer modification timestamp; silently fail instead.
+same or newer modification timestamp;
+instead, silently skip the file without failing.
If the move is across file system boundaries, the comparison is to the
source timestamp truncated to the resolutions of the destination file
system and of the system calls used to update timestamps; this avoids
ln -s no-such-file c || framework_failure_
ln -s no-such-file d || framework_failure_
-returns_ 1 cp --update --no-dereference a b || fail=1
-returns_ 1 cp --update --no-dereference c d || fail=1
+cp --update --no-dereference a b || fail=1
+cp --update --no-dereference c d || fail=1
Exit $fail
# This is a no-op, with no prompt.
# With coreutils-6.9 and earlier, using --update with -i would
# mistakenly elicit a prompt.
- returns_ 1 $cp_or_mv $interactive --update old new </dev/null >out 2>&1 ||
- fail=1
+ $cp_or_mv $interactive --update old new < /dev/null > out 2>&1 || fail=1
compare /dev/null out || fail=1
case "$(cat new)" in new) ;; *) fail=1 ;; esac
case "$(cat old)" in old) ;; *) fail=1 ;; esac