[TUHS] rm command

Derek Fawcus dfawcus+lists-tuhs at employees.org
Thu Apr 26 07:58:58 AEST 2018


On Wed, Apr 25, 2018 at 09:53:26PM +0000, William Corcoran wrote:
> Agreed.  Plus, it’s unmistakable that rm meant “remove” when you examine her sister “rmdir.”
> 
> I think it’s a bit more interesting to uncover why rm does not remove directories by default thereby obviating the need for rmdir—-especially since the potentially nightmarish  incantation of “rm -rf” does include files, folders and just about everything else in between.

Maybe because rm could just be wrapper around unlink,
whereas rmdir also had to remove '.' and '..' before
unlinking the directory?

Or maybe just symmetry with mkdir which had to use mknod,
and manual population of '.' and '..'?

DF



More information about the TUHS mailing list