terminal history search code example
Example 1: ubuntu search for command used
> grep "the_search" ~/.bash_history
--Don't forget the -i flag if you need case insensitive search.
Example 2: command line history search
Ctrl+R
- Start typing a command and the most recent matching command will appear
- Press Ctrl+R again to cycle through results
- Press Enter or Tab to select the result
Example 3: search terminal history
ctrl + R (for linux and osx)