This is not a problem as much as my curiosity of the different cp -r behavior. This is on the latest Ubuntu. I have an outdated copy in a directory with several subdirectories. I'd like to update the outdated copy by simply overwriting the directory with the newer one. New files are added and same file are simply overwritten.
So at first I did:
$cp -r <path>/curr_dir <path>/destination_dir
New files in curr_dir are added but same_name files are not updated, hmm?
But, if I:
$cd <path>/curr_dir $cp -r * <path>/destination_dir/
Then the newer files are added and the outdated files are overwritten.
Why this difference? I checked my .bashrc and my .profile and I don't see any special aliasing of the cp command.
Surely I'm missing something. Any comments, thoughts?