Ctrl-R finds commands that contain the string anywhere. The method the OP posted finds commands that begin with the string. This is an important difference, and if you give it a try, you'll likely agree the latter is what you want most of the time.
ah ok. Thanks for the clarification :)
Thanks for the clarification - although depending upon how you work, this is not much of a benefit. For instance - if you type "/path/to/script.sh" you want to search for the name of the script - not the beginning of the path.
C-r in zsh takes regexp patterns (so you could do *^substr to match begins-only).. I hadn't noticed this wasn't the behavior in bash with readline.
Anyone know if that can be done in bash/readline?
whoops, errant asterisk that I can't edit out. unclosed attempt-to-italicize
In my workflow, I almost always want substring match as that allows me to input either the filename (object) or the command (verb).