Five week fifth class 8.10 Shell special symbol cut command 8.11 Sort_wc_uniq command 8.1

Source: Internet
Author: User


8.10 Shell Special Symbol Cut command
8.11 Sort_wc_uniq Command
8.12 tee_tr_split Command
8.13 Shell Special Symbol

Shell Special Symbols


  • * represents all characters for wildcards
  • ? is a single character
  • is the comment character (in the configuration file or when the command is written in front of the Add # This command will not take effect)
  • \ de-Semantic character cancels the original meaning
  • | Pipe character
    1. Pipe symbol-related commands
  • $ variable prefix,!$ combination, regular inside means end of line
  • Multiple commands are separated by semicolons when they are written to one line
  • ~ User home directory, a match in regular expressions
  • & put commands in the background
  • (> Correct redirection will overwrite the previous file.) >> Chase Emphasis, append content is correct output. 2> error redirection. 2>> Error Append redirect. &> correct and error output redirection)
  • [] A number in the specified character [0-9], range [a-za-z], letter [ABC]
  • | | " or "the meaning." && (to the effect of | | Conversely, if the previous command executes successfully, the next command is executed, and the two are used between commands, equivalent to a judgment command
  • Cut command
  • Cut split intercept string such as # cat/etc/passwd |head-2 |cut-d ":"-F 1 (-D delimiter-F specified segment good-c specifies the number of characters)

*

Sort_wc_uniq command
    • Sort sorts (sort order is usually symbolic number letters)-N is sorted numerically (-n when sorting special symbols and letters are assumed to be 0, sorted in front row)-R inverse-T delimiter (specifies the number of paragraphs to sort)
    • Wc-l statistics Number of rows wc-m statistical characters (# CAT-A file name has a newline character $, so it will be more than the actual number of characters) wc-w statistic Word (the word is split with white space characters)
    • Uniq to repeat (use sort first, use Uniq to weight)-C count rows

      Tee_tr_split command
    • Tee (similar to ">" output redirection) redirection is also displayed on the screen
    • Tee-a Additional content

    • TR Replace character (for character manipulation) tr ' a ' B ', uppercase and lowercase []. If you specify all letters, use [A-z] to mean a to z26 letter range

    • Split cut
    • Split-b 100M bigfile Specify file size cut, one file per 100M
      (If you do not write capacity units "M" Light write numbers, the system by default is divided by bytes, such as 100 is 100 bytes)
    • Split-l Bigfile every 1000 lines into a single file

Five week fifth class 8.10 Shell special symbol cut command 8.11 Sort_wc_uniq command 8.1

Related Article

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.