On Sat, May 05, 2001 at 04:47:47PM -0500, Phil Mendelsohn wrote: > On Sat, 5 May 2001, Carl Wilhelm Soderstrom wrote: > > > If you need that kind of protection, > > > > > > alias rm='rm -i' > > That's what Dave said. rm doesn't need to alias to rm -i, only > rm -(any flags) *. I will continue to disagree... If you had an application which created a crapload of little temporary files as it ran (of course, no _real_ application makes temporary files, right?), all in its own directory, say /var/foo, then forcing rm to be -i any time * is passed as a parameter makes it a little more difficult for that program to clean up after itself - and substantially more difficult for you to clean up after it manually if it crashes. Or perhaps you discover a user who's been hoarding pr0n on your server (but, again, no _real_ user would ever do that). There's a directory with 6573 jpgs of Natalie Portman (naked and petrified, of course) to get rid of. If 'rm *' ignores -f and insists on being -i, you're going to be there all day pressing 'y'. It could even lead to people setting up a new alias: alias rm='yes | rm' in order to bypass the command's overprotectiveness. And I know that I would be one of them. > > "Unix does not stop you from doing stupid things, because stopping you from > > doing stupid things would stop you from doing clever things." Thanks for mentioning this one, Carl. I agree absolutely. Some clever things look stupid (and vice-versa) and computers can't tell the difference. -- That's not gibberish... It's Linux. - Byers, The Lone Gunmen Geek Code 3.1: GCS d? s+: a- C++ UL++$ P++>+++ L+++>++++ E- W--(++) N+ o+ !K w---$ O M- V? PS+ PE Y+ PGP t 5++ X+ R++ tv b+ DI++++ D G e* h+ r y+