My usual pattern when I want to repeat a previous command often implies something along the lines of:
history | grep ... !...
… then I realize I probably typed that command in a different terminal emulator–but which of the currently 90+ open terminal was that?
I have actually broken the up arrow on my keyboard once.
This was when i was starting to use Linux and terminal commands and didn’t know the command enough to type is again. Mainly would occur when installing deb files via terminals going back and forth from installing its dependencies and then the app itself.
I don’t think I could accurately write down most of the commands I use. I think my fingers know those commands better than my head.
CTRL-R is my savior.
I would start typing and then use PgUp
But i agree ctrl r is awesome
Think that pressing 10 times is the enough
Lol, I usually only do this for the more complex commands that I can’t remember.
holds true for me…
I think there are search keys in bash to seach history…
“back in the day” - using Korn shell on Solaris - I’d use “vi” for navigation (set -o vi : which I think even works in bash too) - so I’d use “j” or “k” to scroll up and down in my shell history, and “/” key to search my history, and ESC+ESC would do rudimentary completion (nowhere near as good as bash does, and zsh does it EVEN better )
i was trying to use this magic the other day with an unfamiliar loop mount when i ran into
finally found it in the third one
I used too, but now I use Emacs shell. I simply do a reverse search.
I have a ratty old notebook where I actually WRITE down the commands I use when I am trying something new. I make brief notes of what happened afterward. One time, I even looked back at my notes a couple of weeks afterward!
I have done the same while trying to find my way through a new software project. Saves time and effort.