I'm looking for a concise way to check if a file was copied using
I have a little shell script which updates quite a number of files. At the moment the script
echoes a little message for each file which gets copied.
Now I want to change the script in such a way that the
echo only gets executed when the file actually was updated. I've checked if
cp -u returned an error code if it didn't copy the file, but this isn't the case.
Is there a better way than manually comparing the timestamps of the files?