The best command line trick is using Ctrl-r
to do a reverse-incremental search on your command history.
If you know this trick, you’ll think, “Well, duh”. But if you don’t know this trick, it is pretty freaking amazing.
A Random Walk through Software
Sasha Wood's Thoughts on Programming
The best command line trick is using Ctrl-r
to do a reverse-incremental search on your command history.
If you know this trick, you’ll think, “Well, duh”. But if you don’t know this trick, it is pretty freaking amazing.
I came across this question on Stack Exchange about how to recover from an accidental rm -rf /*
.
The questioner says he runs a small web-hosting service, and accidentally deleted all the files on his servers, and all the files on his backup drives. He asks how to recover. (The answer: it’s difficult.)
This made me smile, because I, like everyone who programs for a living, have an rm -rf
story too.