Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to open a file and save it in linux

2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

How to open a file and save it in linux? I believe that many novice rookies are ignorant of the knowledge that linux opens files and saves. Through the summary of this article, I hope you can gain more. The following information is about? The content of.

For example, to modify the host file

First use the vi / etc/hosts command to open the read mode of the hosts file, press o to enter edit mode, and insert a line after the current location.

After entering the content, press ESC to exit edit mode and enter reading mode.

Command: W save file

Command: Q exit.

Recommended video learning tutorials: linux video tutorials

Edit mode commands:

I: insert at current location

A: append after the current location

O: insert a row after the current location

I: insert in the header

A: append at the end of the line

O: insert a row in front of the current location

Read mode command:

W save the file

W filename is saved as a filename file

Q exit

: q! Forcibly withdraw

: w! Forced writing

Wq save exit

X same as wq

The above is how to open a file and save the knowledge summary in linux, the content is more comprehensive, the editor believes that there may be some knowledge points that we may see or use in our daily work. I hope you can learn more from this article.

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.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report