In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-09-21 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/03 Report--
Echo
The echo instruction can output the content to standard output, dividing the string with white space, followed by a newline.
The scope of application of this command: RedHat, RHEL, Ubuntu, CentOS, Fedora.
1. Grammar
Echo [- neE] [arg...]
2. List of options
Option
Description
-n
The output string does not wrap
-e
Dealing with some special characters
\ a buzzer alarm
\ b Delete the previous character
\ C finally, there is no line change.
\ e output esc characters
\ f Wrap, the cursor stops in the same place
\ nWrap
\ r move the cursor to the first line without wrapping
\ t horizontal tab
\ v Vertical tab
\\ output\
The ASCII character represented by\ 0nnn octal nnn
\ xHH the ASCII character represented by the hexadecimal number HH
-E
Disable escape interpretation
3. Examples
1) use "\ f" line feeds
[root@localhost ~] # echo-e "hello\ fworld" / / the-e option must be used, and the cursor is still at the end after\ f wrapping
Hello
World
[root@localhost ~] #
2) use "\ n" line feeds
[root@localhost ~] # echo-e "hello\ nworld" / / the-e option must be used,\ nAfter a line break, the cursor is at the beginning
Hello
World
[root@localhost ~] #
3) output ascii characters
[root@localhost ~] # echo-e "\ x31" / / 31 in hexadecimal, converted to 49, the ascii character represented is 1
one
[root@localhost ~] #
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.
The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.