Re:Control-R, my favorite Unix shell command
by gbog on Sunday May 18, 2014 @08:08PM
(#7765002)
Why not arrow up? That's what I use and it is very natural.
[ Parent
| on HN ]
Me too. And not entering anything gives normal arrow up, so there's no loss.
BTW: ^r is a little more powerful: it is /string/ while this one is /^string/
BTW ^r annoyance: you can't type and then hit ^r. You have to hit ^r first. Seems easy to fix...
BTW tip: if you like readline features, consider rlwrap: it wraps its argument (which is your command) in readline. e.g. rlwrap python. Especially nice to wrap your own interactive cmdline tool.
Thanks for the tip on rlwrap, that looks really useful!