Hacker News new | ask | show | jobs
by tp34 1052 days ago
shopt -s dotglob
1 comments

Yes. Or one lowtech method I use often is `touch ~/-i`. When someone tries to rm -rf * the file called “-i” gets globbed at the front of the arguments and the subsequent command goes into “interactive “ mode meaning it prompts y/n for each file
Nice! Great "bug as a feature" trick!