📎 Webclip
Ctrl+R Autocomplete with Bash is a Life Saver
The post says Ctrl+R was added recently to the author’s command-line workflow and quickly became useful. It uses reverse-i-search to autocomplete from .bash_history, so the user can find old commands without repeating up many times.
It also says the flow feels natural in use. After finding a command, you can press return to run it or use the left and right arrows to edit it, and you can keep pressing Ctrl+R to cycle through results if the exact command or parameters are not immediately clear.
Reading notes#
- Ctrl+R recently entered the author’s command-line workflow and became very useful.
- The
reverse-i-searchcommand searches in.bash_historyand reduces the need to repeatupmany times. - When locating the right command, it is possible to press return to execute it or use the left and right arrows to edit it.
- If the command or the parameters do not appear immediately, you can keep pressing Ctrl+R to switch between the results.
- The author says the behavior is natural and encourages those who still depend on repeated
uppresses to try the shortcut.
