User Manager deletes home directory without prompt
|Reported by:||Nukama||Owned by:||tim|
This should be definitely an optional choice. There is a reason for hiding this devastating user removal behaviour into a knob only visible after reading manpage/help.
-r This tells pw to remove the user's home directory and all of its contents. The pw utility errs on the side of cau- tion when removing files from the system. Firstly, it will not do so if the uid of the account being removed is also used by another account on the system, and the 'home' directory in the password file is a valid path that com- mences with the character `/'. Secondly, it will only remove files and directories that are actually owned by the user, or symbolic links owned by anyone under the user's home directory. Finally, after deleting all contents owned by the user only empty directories will be removed. If any additional cleanup work is required, this is left to the administrator.