Under Linux to do development, or even only to do management and maintenance work, but also the use of vim. As a novice, I am also just in touch, this section of my daily use or collection of vim common commands recorded.Of course, you can learn all
I am using Ubuntu 12.04. When using Vim to open a file of the file type "ISO-8859 C program text", the Chinese characters in it are garbled, this is because Vim cannot automatically identify the file encoding type. You need to modify the vim
When editing with vim, it is often difficult to edit multiple files or to edit a file by referring to other files. Here are two methods:
1. Multiple tags
Enter:
Name of the vim-P file to be edited
For example, VIM-p * is used to edit all files
Vim-visualized operations
Vim supports the following visual operations:
V → single character selection.V → select a row at a time. → block selection. It is very powerful to work with keys a and I.GV → after exiting the visualization mode, you
1. Use vim and ctags/cs.pdf.
In Linux, we provide a complete IDE and VIM Quick Start-run vimtutor directly to familiarize yourself with vim commands according to the training requirements.
Ctags/csags to helpProgramBrowsing the program.
In centos, only vim-minimal-7.x is installed by default. Therefore, whether you enter VI or Vim to view files, the syntax function cannot be enabled normally. Therefore, you need to install two other components with Yum: vim-common-7.x and
Some advanced editors will contain macro functions, which are certainly not missing in Vim. It is very convenient to use Macros in VIM:
: QX starts to record macros and saves the results to register xQ exit record mode@ X macro commands for
Common Vim operations, plug-ins, and vimrc files
First:
My custom color scheme:
The evening color scheme of the system:
1. Common OperationsVim, as a text editor, is powerful. In my opinion, it is quick editing, and rich extension plug-
1. securecrt
Settings in session
1) Session option → select the font (New, or others), and select chinese_gb2312 for the character set.
2) Vim/etc/sysconfig/i18n
Lang = "zh_CN.UTF-8"
3) VI ~ /. Bash_profile
Export lang = zh_CN.UTF-8
2.
Download and install python.
Download Vim from the vim website.Self-installing executable.
Edit the vim configuration file _ vimrc
Copy the stuff in vimrc_example to _ vimrc
Remove source $ vimruntime/vimrc_example.vim from _ vimrc.
Set Chinese
Method 1Go to the vim official website under the CVIM plug-in (http://www.vim.org/scripts/script.php? Script_id = 213). If not, go to the vim official website and enter the CVIM keyword to search.Decompress the package directly to your. Vim folder
This article is well organized on the Internet, and its form is as follows:
Formal expression
Description and Examples
Unmatched strings
//
String containing the letter "A", such as "AB", "BAC", and "CBA"
"Xyz"
Use Vim to develop software projects-(2) sessions and viminfo
The help entry for the commands used in this section:: Help mksession
: Help 'sessionoptions'
: Help Source
: Help wviminfo
: Help rviminfo
: Help 'viminfo
Many software have this
For vimist, neocomplcache is a plug-in that is both love and hate. The main feature is powerful, complex configuration, and like to conflict with various plug-ins.
I was also overwhelmed by him. During this period, you searched countless times, but
Well, what I'm talking about here is not how to use tabnew in the terminal to open a new tag, but how to use gvim to open a new file in windows, it is opened on the gvim tab by default.
Here there are two main methods, in fact, the principle is the
The operating system is centos 5.3, PHP 5.1.6, and xdebug 2.0.5.References:Xdebug installation documentation: http://xdebug.org/docs/install.Xdebug remote debugging Configuration documentation: http://xdebug.org/docs/remoteUsing vim and xdebug dbgp
Document directory
Select The Right Mode)
You can download the original Vim Recipes text from runpaint.
Select The Right Mode)
Problem
Although you know that Vim has multiple operation modes, you are not sure when to use them.
Solution
There
Summary:Install vim --> Configure the/etc/vim/vimrc FileThis enables vim to support syntax highlighting, automatic indentation, and other functions. Currently, the content of the vimrc configuration file is as follows, and basic c/c ++ programming
I learned some simple mobile shortcuts for vim last time and used them for a period of time.
You are already familiar with these shortcut keys.
Continue learning now
This time, we will summarize some shortcut keys for inserting, searching,
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