bash history & completion tips
Author: webmaestro
This is an oldie… bind the up and down arrow keys to searching `bash` history:
http://www.macosxhints.com/article.php?story=20031026174236860
Type this into vi ~/.bash_profile, and in place of
<up>type control + v, then up arrow. In place of
<down>type control + v then down arrow. (Control V tells vi to put the next character in the doc, rather than just moving up when you press up arrow etc.)
bind '"<up>":history-search-backward' bind '"<down>":history-search-forward'Then close all Terminal windows, and quit the app, then open Terminal again and you should have the feature.
also…
PS, don’t forget to add these to your .inputrc while you’re at it:
set show-all-if-ambiguous on
set completion-ignore-case on
June 12th, 2007 at 2:48 pm
Is this working? I’m just testing things here. type control + v is a nice bash tip.