logoalt Hacker News

antonvstoday at 4:00 AM3 repliesview on HN

I've had agents run `rm -rf`, but it's been on directories that did actually need to be removed. To a certain extent I think the existence of `rm -rf` as a command that runs blindly without any understanding of what it's deleting is the problem.


Replies

KronisLVtoday at 9:59 AM

> To a certain extent I think the existence of `rm -rf` as a command that runs blindly without any understanding of what it's deleting is the problem.

Yes, and the lack of a Recycle Bin of any sort is even more puzzling. I think both servers and desktop PCs across all OSes should have it by default, so unsafe deletes would be something you'd have to go out of your way to even enable.

dumbdumb125today at 4:25 AM

I've had one sever its own internet connection. Less destructive, also more humorous.

lstoddtoday at 4:21 AM

the answer is rm -f `which rm`, yes?