stty
stty
stty [options] [modes]
Set terminal I/O options for the current standard input device. Without options, stty reports the terminal settings that differ from those set by running stty sane, where ^ indicates the Ctrl key and ^` indicates a null value. Most modes can be negated using an optional - (shown in brackets). The corresponding description is also shown in brackets. Some arguments use non-POSIX extensions; these are marked with *.
Options
Report all option settings.
Open the specified device and use it instead of standard input.
Report settings in stty-readable form (i.e., hex).
Print help message and exit.
Print version information and exit.
Control modes
[Enable] disable modem control.
[Disable] enable the receiver.
[Disable] enable RTS/CTS handshaking.
Set character size to bits, which must be 5, 6, 7, or 8.
[1] 2 stop bits per character.
[Do not] hang up connection on last close.
Same as previous.
[Disable] enable parity generation and detection.
Use [even] odd parity.
Input modes
[Do not] signal INTR on break.
[Do not] map CR to NL on input.
[Do not] ignore break on input.
[Do not] ignore CR on input.
[Do not] ignore parity errors.
When input buffer is too full to accept a new character, [flush the input buffer] beep without flushing the input buffer.
[Do not] map NL to CR on input.
[Disable] enable input parity checking.
[Do not] strip input characters to 7 bits.
[Do not] map uppercase to lowercase on input.
Allow [only XON] any character to restart output.
[Enable] disable sending of START/STOP characters.
[Disable] enable XON/XOFF flow control.
[Do not] mark parity errors.
Output modes
Select style of delay for backspaces (0 or 1).
Select style of delay for carriage returns (0-3).
Select style of delay for formfeeds (0 or 1).
Select style of delay for linefeeds (0 or 1).
Select style of delay for horizontal tabs (0-3). tabs is the same as tab0 and -tabs is the same as tab3.
Select style of delay for vertical tabs (0 or 1).
[Do not] map CR to NL on output.
Set fill character to [NULL] DEL.
Delay output with [timing] fill characters.
[Do not] map lowercase to uppercase on output.
[Do not] map NL to CR-NL on output.
On the terminal, NL performs [does not perform] the CR function.
Do not [do] output CRs at column 0.
[Do not] postprocess output.
Local modes
[Do not] echo every character typed.
[Do not] echo ERASE character as BS-space-BS string.
[Do not] echo NL after KILL character.
[Do not] echo NL.
[Disable] enable canonical input (ERASE, KILL, WERASE, and RPRINT processing).
[Disable] enable extended functions for input data.
[Disable] enable checking of characters against INTR, SUSPEND, and QUIT.
[Enable] disable flush after INTR or QUIT.
[Do not] send SIGTTOU when background processes write to the terminal.
[Do not] change case on local output.
When erasing characters, echo them backward, enclosed in and /.
Do not echo control characters literally. Use hat notation (e.g., ^Z).
Erase characters as specified by the echoprt and echoe settings (default is echoctl and echok settings).
Control assignments
Set control character to c. ctrl-char is dsusp (flush input and then send stop), eof, eol, eol2 (alternate end-of-line), erase, intr, lnext (treat next character literally), kill, rprnt (redraw line), quit, start, stop, susp, swtch, or werase (erase previous word). c can be a literal control character, a character in hat notation (e.g., ^Z), in hex (must begin with 0x), in octal (must begin with 0), or in decimal. Disable the control character with values of ^- or undef.
Set the minimum number of characters that will satisfy a read until the time value has expired when -icanon is set.
Set the number of tenths of a second before reads time out if the min number of characters has not been read when -icanon is set.
Set line discipline to i (1-126).
Combination modes
Same as [raw] -raw.
Same as [-] parenb and cs[8] 7.
Reset ERASE and KILL characters to Ctrl-h and Ctrl-u, their defaults.
[Unset] set xcase, iuclc, and olcuc.
[Unset] set icrnl and onlcr. -nl also unsets inlcr, igncr, ocrnl, and onlret, icrnl, onlcr.
Same as [-] parenb, [-] parodd, and cs7[8] .
[Disable] enable raw input and output (no ERASE, KILL, INTR, QUIT, EOT, SWITCH, or output postprocessing).
Reset all modes to reasonable values.
Same as [icanon] -icanon.
Same as -parenb -istrip cs8.
Same as -parenb -istrip cs8.
Same as -ixany.
Same as echoe echoctl echoke.
Same as echoe echoctl echoke -ixany. Additionally, set INTERRUPT to Ctrl-C, ERASE to Del, and KILL to Ctrl-U.
Special settings
Set terminal baud rate to n (e.g., 2400).
Specify input speed.
Specify output speed.
Specify number of rows.
Specify number of columns.
Display current row and column settings.
Display terminal speed.