Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Backspace key which produces ^? 1

Status
Not open for further replies.

ddrillich

Technical User
Jun 11, 2003
546
0
0
US
Good Day,

When pressing the backspace key, ^? is displayed. What can I do to get the expected behavior?

Regards,
Dan
 
All,

stty erase 'Press backspace' does it.

How do I do it for the up and down arrows?

Regards,
Dan
 
What shell are you using?

In the Korn shell you can issue these commands...

Code:
# Set-up keyboard arrow keys to function like arrow keys (up,down,left,right)
     alias __A=^P
     alias __B=^N
     alias __C=^F
     alias __D=^B
     set -o emacs

...and it will enable command line recall and editing with the arrow keys. It basically makes the Korn shell act like bash command line editing.

Note, the ^P is actually Ctrl-P, ^N is Ctrl-N, etc.

 
Thank you Sam. I was using the Korn shell. Switching to bash makes sense.

Regards,
Dan
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top