4.6. Useful Keys and How to Get Them to Work
When you type a command, pressing the Backspace key should remove the last character. Ctrl-U should delete the whole line. When you have finished entering a command, and it is executing, Ctrl-C should abort it, and Ctrl-Z should suspend it. (When you want to resume the program, enter fg for "foreground.")
stty function key
Here is a set of sample commands to set up the functions described earlier:
$ stty erase ^H $ stty kill ^U $ stty intr ^C $ stty susp ^Z
The first control key shown, ^H, represents the ASCII code generated by the Backspace key.
By the way, you can generate a listing of your current terminal settings by entering stty -a. But that doesn't mean you can understand the output: stty is a complicated command with many uses, some of which require a lot of knowledge about terminals.
Copyright © 2001 O'Reilly & Associates. All rights reserved.