In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-08 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article is about how linux uses the cat command to view files. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.
What is Linux system Linux is a free-to-use and free-spread UNIX-like operating system, is a POSIX-based multi-user, multi-task, multi-threaded and multi-CPU operating system, using Linux can run major Unix tools, applications and network protocols.
When viewing the contents of a file on a Linux system, you can use the cat command to view it, but the cat command is generally suitable for viewing files with less file contents.
1. The syntax format of the cat command is: cat [parameters] [file]
For general viewing, you can directly use the cat file name, such as viewing the yum.conf file.
The command is cat yum.conf
2. If you need to display the number of lines in the file, you can use the parameter-n
The command is: cat-n yum.conf
3. The-n parameter will number each line of the file, even if it is a blank line. If you need multiple blank lines to be counted as a number, you can use the-s parameter
The command is: cat-s yum.conf
4. If the contents of the file are displayed without numbering blank lines, you can use the command-b
The command is: cat-b yum.conf
5. sometimes in order to distinguish the end of each line, you can use the command-E to display the $symbol at the end of each line.
The command is: cat-E yum.conf
6. In special cases, you need to display TAB characters as ^ I symbols, and you can use the parameter-T
The command is: cat-T yum.conf
7. If you need to check the specific usage of cat, you can use the command-help to display help information.
The command is cat-- help or cat-- h
8. You can use the parameter-version to view version information
The command is cat version
Thank you for reading! This is the end of this article on "how linux uses cat commands to view files". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, you can share it out for more people to see!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
Insert into myTable values (5 2019 cast ('{"": [{"u": 1, "t": 123}]}'as json))
© 2024 shulou.com SLNews company. All rights reserved.