Home >Operation and Maintenance >Linux Operation and Maintenance >Which command in vi is to force exit without saving?

Which command in vi is to force exit without saving?

尚
Original
2020-01-06 13:29:0819423browse

Which command in vi is to force exit without saving?

All Unix Like systems will have a built-in vi document editor, but other document editors may not exist. But currently we use the vim editor more. Vim is a text editor developed from vi.

The "q!" command in vi forces an exit without saving.

Some common commands in vi:

:w save;

:w filename save as filename;

:wq ! Save and force exit;

:wq! filename Note: Force exit after saving with filename as the file name;

:x Save and exit (only save when the file has changed)

Recommended learning: linux tutorial

The above is the detailed content of Which command in vi is to force exit without saving?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn