Www.vim.org command: Set nu to use VI more quickly, we need to master several sets of commands {#1, [INSERT command] A, A, I, I, O, O #2, [positioning command] H, J, K, L, $, 0, H, M, L: Set nu to set the row number: setnonu cancel the number Gg to
Some terminals can be restored to the status of the terminal before vim is enabled after Vim is exited, similar to the following:
$ Vim/etc/sysconfig/
#### Enable Vim #####
Sdskk, some file content
: Q
$ Vim/etc/sysconfig/# restore the
When you use Vim to open a file and edit it, Chinese garbled characters appear in the bottom taskbar, seriously affecting the compilation.CodeThe reason is that Vim does not support the default language. By modifying the/etc/vimrc configuration file,
Vim 7.0 and later versions have built-in auto-completion, with the same shortcut key as omnicppcomplete.
CTRL + x Ctrl + O (Intelligent completion)
Or Ctrl + n
Or Ctrl + P,
Or Ctrl + x Ctrl + f (fill in the file name)
CTRL + X is to enter a
This article sets Vim only for Ubuntu and Fedora systems. In ubuntu, the vim configuration file is stored in the/etc/Vim directory, and the configuration file name is vimrc.
In fedora, the vim configuration file is stored in the/etc directory. The
On G +, we can see the introduction from netizens and find that Vim can highlight the code into HTML documents according to the current syntax. This is a very considerate small function.
For me, this function has at least two functions. First, put
Although Vim has been used to write programs and documents, it has not been used to explore the specific usage of its tab page function. Now I am paying attention to this issue. After all, it takes less and less time to use Vim. Of course, this is
1. Split the screen to start Vim
Use the uppercase o parameter to split the screen vertically. Vim-on file1 file2... use the lower-case o parameter to split the screen horizontally. Vim-on file1 file2...Note:N is a number, which indicates several
Qtcreator is really tough to use. Use vim. Plug-in omnicppcompletion, generate the tags of STL and qt4 as the basis for all-around completion, and then generate
Tags is used as a jump and complete update.
Different from the reference:
1. The
Some common operations of VIM plug-in zencoding
Pretty cool, record some common operations
Easy to install, no longer like I used sparkup. Vim to configure the python environment, can be directly connected to the
From: http://blog.csdn.net/jixiuffff/article/details/5695806
Install Vim first (of course, JDK installation is required for Java development)
Emerge-AV Vim (install the vim command on the Gentoo system, you can use rpm, Apt-Get)
Install the
Note:
In the following example, xxx indicates entering XXX in command mode and press Enter.
In the following example: XXX indicates entering XXX in extended mode and press ENTER
The commands in parentheses indicate related commands.
The command
Make up your mind to configure vim.
Basic Configuration
Terminal operation:
vim ~/.vimrc
The configuration is as follows:
Set nocp "set compatible with set expandtab" set tabset shiftwidth = 4 "set the tab interval set tabstop = 4" four spaces
In ubuntu, the vim configuration file is stored in the/etc/Vim directory. The configuration file name is vimrc.
In fedora, the vim configuration file is stored in the/etc directory. The configuration file name is vimrc.
Enter the following command
Http://blog.chinaunix.net/uid-346158-id-2131115.html
In the work, it is suspected that the width of a tab in VIM is too large. In the Debian system, the width is 8 characters before it is changed. to change it to 4, see the following:Cd ~Vim.
1. Import copyright information at the beginning of the file
Copyright information usually needs to appear at the beginning of each source code file. This part of content is the same and there is no need to repeat the input. Even copying and
View File encoding
Highlight the current row set cursorline
Highlight the current column set cursorcolumn
Delete linefeed J
Definition of work iskeyword
Exchange two characters in XP
Move to the end of GE <> E blank Definition
Blank and bounded
"The file is automatically updated when it is modified externally.Set autoread
"Highlight the current rowSet cursorlineHi cursorline guibg = #222222Hi cursorcolumn guibg = #333333
"Enable foldSet nofenSet FDL = 0 "Set the tab key to 4 spaces.Set
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