Karl Berry wrote: > [coreutils 8.1, gnu/linux] > > $ touch foo > $ ln -s foo lnk > $ \cp --no-dereference foo lnk > cp: `foo' and `lnk' are the same file > > Well, no, they're not. > I expected the file foo to overwrite the symlink lnk. > I can imagine that error without --no-dereference, but with it ... ?
As far as I understand it cp -P,--no-deref only applies to the source. There are different rules for the destination, and you would need to be explicit with --remove-dest for example. cheers, Pádraig.
