1. Enter the character interface
2. Create a folder for storing source files
mkdir HelloWorld//Create Folder command
CD HelloWorld//Enter the new folder, this should be said that the directory is better, windows with the habit of
vim main.c//Open
Brief Introduction
Vim has become very powerful after configuration, enough for us to do our daily tasks, but these are not enough to match the IDE. This time VIM's more powerful extension mechanism stands out, vim can install a variety of plug-ins.
VI (VIM) is a very common code Editor on Linux, many Linux distributions are installed by default VI (VIM). VI (VIM) command a wide range but if used flexibly will greatly improve the efficiency. VI is "visual interface" abbreviation, VIM is VI
vim Practical Small Command
1. How to paste command line modeThere are two modes of general VIM: Command line mode and edit mode
When we press the ESC key and then enter: After that, we enter the command mode, and then we can enter the command.
But
Fix vim input Validation Vulnerability
CentOS 6, vim 7, cve-2016-1248
Aliyun has advertised Vim 7 's input verification vulnerability, a security vulnerability in the previous version of Vim patch 8.0.0056, which stems from the program's failure
The move keys available in VI Command mode:
h---move the cursor one character to the left
j---move the cursor down one character
k---move the cursor up one character
l---move the cursor one character to the right
w---move the cursor forward one word
1. Normal mode (Normal-mode)
The default is in normal mode when Vim is started. Regardless of the mode, press the key (sometimes required to press two) to enter normal mode.
2. Insert mode (Insert-mode)
Pressing I, I, a, a, and so on in normal
VIM handles strings with a look around to facilitate complex deletion and replacement operations
For an explanation of the look, please refer to Yurii's "proficient in regular expression" book.
If you have the following
Vim Program Editorbasically VI It is divided into three modes, namely General instruction mode, edit mode and instruction column command mode.General instruction Mode : Open a file to go in, he can delete, copy, paste and other operations, but can
When Vim of cream version is installed, garbled characters are found. Garbled characters in the installation wizard can be ignored; start after installationProgramThe following menu is garbled:
And the use of Windows context menu items (edit with
With VIM + cssag/ctags, You can implement the sourceinsight function. In the future, you can stop using pirated souceinsight to readCode.Add the cscope function. after vimrc (you need to select the "-- enable-cscope" option during vim compilation;
From: http://blog.sina.com.cn/s/blog_622d95080100ny94.html
In ~ /. After set mouse = A is added to vimrc, the right-click Vim cannot be copied. The solution is as follows:
Press and hold the Shift key, and then select. At this time, X processes the
To do their best, you must first sharpen your tools.
As an essential tool for Linux development, being able to maximize the effectiveness of VI will inevitably improve our work efficiency. Below are some tips for using vi.
1. Position the cursor
This article has been translated into French by Geoffrey Bachelet. You can read the French version here: l'privacy ition efficace avec vim. "To me, VI is Zen.To use VI is to practice Zen.Every command is a koan.Profound to the user,Unintelligible to
Via: Kevin Watters's blogTranslation: xguru
Original StatusI have watched a violin player play with great passion. I have this idea: Maybe I have invested almost the same number of brain cells in the text editor as I have played a favorite
Supplement:
VI display row number:
: Set nu
: Set number. The row number is displayed on the left of each row.
: Set rexample row number displayed in the lower right corner
Set numberwidth = n when each row has a small space, it is not prefixed with
Wcdj
Winhex is a small tool dedicated to dealing with various daily emergencies. It can be used to check and repair various files, restore and delete files, and data loss caused by hard disk damage. It also allows you to see the files and data
Reprinted please indicate this blog from "LIU Da csdn blog": http://blog.csdn.net/poechant
1. Multi-file editing mode
(1) The argument list mode contains multiple file path parameters when opening the vim editor.
(2) buffer list mode: after
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service