Linux cat命令,linuxcat命令

來源:互聯網
上載者:User

Linux cat命令,linuxcat命令
介紹

cat命令經常會用來查看一個檔案的內容,並且結合它本身的一些參數經常可以用來做一些特殊的內容處理。

 

 

參數

Usage: cat [OPTION]... [FILE]...Concatenate FILE(s), or standard input, to standard output.  -A, --show-all           等同於使用參數-vET  -b, --number-nonblank    針對非空行顯示行號  -e                       等同於使用參數 -vE  -E, --show-ends          每行以$結尾-n, --number             每行都顯示行號  -s, --squeeze-blank      將連續的多個空行以顯示一個空行  -t                       等同於使用參數 -vT  -T, --show-tabs          定位字元(tab)以^I符合代替  -u                       (ignored)  -v, --show-nonprinting   use ^ and M- notation, except for LFD and TAB      --help     display this help and exit      --version  output version information and exitWith no FILE, or when FILE is -, read standard input.Examples:  cat f - g  Output f's contents, then standard input, then g's contents.  cat        Copy standard input to standard output.

 

1.查看多個檔案內容

2.顯示行號

3.壓縮空行

4.不顯示空行

 

總結

 

 

 

 

備忘:

    作者:pursuer.chen

    部落格:http://www.cnblogs.com/chenmh

本網站所有隨筆都是原創,歡迎大家轉載;但轉載時必須註明文章來源,且在文章開頭明顯處給明連結。

《歡迎交流討論》

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

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.