| |
Make Arrow Keys work on AIX, HPUX, etc
#
# various hints for screen and command line editing
#
EDITOR=vi ; export EDITOR #silently does a set -o vi
VISUAL=vi ; export VISUAL #silently does a set -o vi
set -o emacs #silently does a set -o emacs :-)
#
# make arrow keys work by mapping the escape sequences the arrow keys send
# to the corresponding emacs-ish control characters.
# since these aliases are mapping keystrokes and not commands we need
# backticks (capture the *effect* of the command into the alias).
#
if uname -a |grep -qi -e ^aix -e ^hp ; then
alias __A=`echo "\020"` #ctrl-p => up
alias __B=`echo "\016"` #ctrl-n => down
alias __C=`echo "\006"` #ctrl-f => right
alias __D=`echo "\002"` #ctrl-b => left
fi
date: 01/05/2011
|