control shift R, then start typing, it will search your bash history
I recommend using mcfly for that, it makes it even better.
Ctrl+R
Then type any part of the command (filename, search string, etc)
Ctrl+R again to cycle through the matches.
(Best feature in bash)
Use fzf for a more visual search.
It’s like the bus-stop-paradigm: If I wait just a bit longer and it will come. Meanwhile it would’ve been faster to walk.
history | grep 'command'
I use this all the time. Even better if you add it as a function.
This is why I switched to fish; it seems to be much smarter understanding what I want to type.
Yeah it’s great how ctrl-r is kinda the default instead of something you have to go out of your way to use. Just start typing a command and the up arrow will only cycle through history that matches what you’ve typed so far.
i use vi mode in zsh for that reason, its pretty good