"Linux" about the use of minus sign-

Source: Internet
Author: User

Pipeline commands are quite important in Bash's continuous processing program! In addition, in the analysis of log file is also a very important link, so please pay special attention! In addition, in the pipeline command, often using the stdout of the previous command as the stdin, some commands need to use the file name (for example, tar) for processing, the stdin and stdout can use the minus "-" to replace, for example:

Tar Tar -xvf-

The above example says, "I'll pack the files from home/home, but the packaged data is not recorded to the file, but to the stdout; after the pipeline, TAR-CVF-Home is routed to the back TAR-XVF-". The following-is the stdout of the previous command, so we don't need to use file! This is a very common example! Pay attention!

 Reference:http://vbird.dic.ksu.edu.tw/linux_basic/0320bash.php#pipe_7

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.