Linux stty command __linux

Source: Internet
Author: User

Stty a common command used to change and print terminal line settings

1, at the command line, prohibit the output of uppercase method

Stty IUCLC #开启
STTY-IUCLC #恢复
2, prohibit output lower case at command line
Stty OLCUC #开启
stty-olcuc# Recovery
3, print out the terminal number of rows and columns
Stty size
4, change the Ctrl+d method:
Stty EOF "string"
The system defaults to Ctrl+d to indicate the end of the file, which can be changed by this method!

Note: If you change the default of EOF see Ctrl+d, and then want to change back, you can use the following command

Stty EOF ^d

of which, ^ is the ctrl.

5, Shielding display
Stty-echo #禁止回显
Stty Echo #打开回显
Test method:
Stty-echo;read;stty Echo;read
6, ignoring the carriage return character
Stty IGNCR #开启
stty-igncr# Recovery

7, prohibit the background job to control the terminal output

Stty tostop #开启

Stty-tostop #恢复

8, Tee command

The tee command is used to read the contents of the standard input and then write to the file and standard output.

Command format tee [optons] [file]

There are three options available:

-A: Append mode is used when writing to a file, rather than overwriting previous content.

-I: Ignore the interupt signal.

-h:help

-v:version

Note: The file is not specified, so that only output to standard output.

9, OD command

Output the contents of a file in octal or other format to standard output (available to view the contents of a non-text file).

OD commands use the following format:

od [OPTION] ... [FILE] ...

Example:

Od-b-A D testfile

The above command outputs the contents of the file Testfile in eight (3 bits per byte) to the standard output, and the output time address is in 10 notation (the-B option specifies that each byte is output in octal number, the-a D option specifies to output the address in decimal digits).

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.