| ▲ | mqus 2 hours ago | |||||||||||||||||||||||||||||||
would you be safe in using --recursive always? (e.g. shell scripts) | ||||||||||||||||||||||||||||||||
| ▲ | olowe 2 hours ago | parent | next [-] | |||||||||||||||||||||||||||||||
There are implementations of cp out in the wild that do not recognise the --recursive flag. OpenBSD was mentioned in the article and there’s also busybox cp https://busybox.net/downloads/BusyBox.html | ||||||||||||||||||||||||||||||||
| ▲ | hnfong 2 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||
Double dash long options are basically a GNU extension. BSD utilities generally don't support them. Apparently macOS does not either (since it's based off of FreeBSD) | ||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||
| ▲ | dotancohen an hour ago | parent | prev [-] | |||||||||||||||||||||||||||||||
I believe that -R is the safe works-as-expected-everywhere option. | ||||||||||||||||||||||||||||||||