VI/VIM editor and vivim Editor1 Overview
All Unix Like systems have built-in vi file editors, while other file editors do not necessarily exist. However, we currently use the vim editor.
Vim
cursor by line number is a quick way to move the cursor in a large file.Summary of the vi editor commands in this chapter:^ F, ^ B, ^ D, ^ U, ^ E, ^ Y, z + enter, z ., z-, ^ L, H, M, L, enter, +,-, ^, n |, e, E ,(,),{,}, [[,],/pattern ,? Pattern, n, N ,/,?, Fx, Fx, tx, Tx,;, G, '','', ^ G.
How to learn the Chinese version of VI and VIM
Vi/vim Basic Use MethodThis article introduced the VI (VIM) basic use method, but for the ordinary user is basically enough. I/vim the difference is simple, they are multimodal editor, the difference is that vim is
VI VimLinux has multiple editors, but different distribution, VI is basically supported on every distribution.Vim is an enhanced version of VI. Vim has the ability to edit the program, can be active in font color to identify the correctness of the grammar, convenient program
highlighting function. You can continueOther feature settings of Huan are added to the vimrc file.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The Vim tutorial ends now. This tutorial is only intended to briefly introduce the vim editor, but it is sufficient for youThis editor is easy to use. There are many other commands in vim.Shao is still far away. So if you want to
CentOS learning notes-vi program editor, centos learning notes-viVi program editor
In Linux, you often need to modify some configuration files. In this case, you need an editor. Almost all Linux versions provide the vi editor.File Content Check cat command
What should we do if we want to check the content of a file? Th
Turn from: http://www.lupaworld.com/?uid-296380-action-viewspace-itemid-118973
Vi/vim Basic Use MethodThis article introduced the VI (VIM) basic use method, but for the ordinary user is basically enough. I/vim the difference is simple, they are multimodal editor, the differe
Vi/Vim prompts the worker who has no permission to save
Sometimes, when we use Vi/Vim to edit a file, if we do not notice the File Permission, the following error may be prompted when we finally save the file. If the user is forcibly exited, the current changes will be lost. I will share with you a method that does no
be shared between different sessions.The personalization of VimGlobal configuration file:/ETC/VIMRCUser profiles: ~/.VIMRCSet: Execute in extended mode or write to config file
Nu Display Line number
IC ignores character case
Ai Auto Indent
Si smart Indent
Hlsearch Highlight Search
The list shows tab and line breaks ^i and $
Ff=dos|unix Enable UNIX Format | Windows format
textwidth=# Setting the text width
Cursorline set the identification line of the lin
They are multi-mode editor, the difference is that Vim is the upgrade version of VI, it is not only compatible with all VI directives, but also some new features inside.These advantages of vim are mainly reflected in the following aspects:1. Multilevel undoWe know in VI, pre
They are multi-mode editor, the difference is that Vim is the upgrade version of VI, it is not only compatible with all VI directives, but also some new features inside.These advantages of vim are mainly reflected in the following aspects:1. Multilevel undoWe know in VI, pre
why to use VI.
VI is a very unfriendly text editor, but why use it. Because: all Unix like systems will build a VI editor, and other text editors are not necessarily present; a lot of the editing interfaces of the software will call VI Vim's ability to edit the program, and
: ctrl + t
3. Set multiple tags paths: Just jump across your project. What should I do if I want to see the system function? Use :! Man is fine, but what should I do if I want to see python library functions?
You can edit your own vimrc directly in vi: e $ MYVIMRC, but of course you don't need to input so much. After entering MY, you can use the tab to complete it,
Set tags =./tags,/usr/lib/python2.6/tags
4. Display All tags of a keyword:
: Ts keyword
Vi/vim Basic Use MethodThe VI Editor is the standard editor for all UNIX and Linux systems, and its power is not inferior to any of the latest text editors, here is simply a brief introduction to its usage and a small number of instructions.1, VI of the basic conceptBasicall
displayed on the left and the set does not add "number" and is a separate line.Set tabstop=4//tab length to 4Set nobackup//Overwrite files without backupSet Cursorline//Highlight when forwardSet ruler//display status line at cursor position in lower right cornerSet autoindent//Auto IndentSet SmartindentWhen you are finished, press "ESC" and then "shift+:?" Input Wq, enter save exit, this vim configuration is complete.Find an example to try the effect
character entered from the keyboard is interpreted as an edit command, and if the input character is a valid VI command, VI completes the corresponding action after accepting the user command. Note, however, that the commands you enter are not displayed on the screen. If the input character is not a legal command of VI, VI
specify the comment range, that is, the current line and the subsequent three lines of code. In fact, there is a simpler way:
This command replaces the beginning of a line (^) with "//", "^" indicates the beginning of a line (this is a logical concept and is not an actual character, therefore, the actual first character of the line will not be replaced ).
(11) add a full stop at the end of all lines of the file:": % S/$ /./".
(12) reverse the order of all parts separated by hyphens:
(13) conv
Vi/vim Keyboard Diagram-----Another desktop background good pictureMaybe there are a lot of people who are not willing to use the CLI vi/vim to write things, but when you really get used to it, its efficiency is immeasurable. The following picture, a look to understand, from now on,
Linux environment Editor has VI, Vim, gedit, after entering these editors, display the current line number
Manual display: Input in vim or vI command line mode : Set nu
Cancel display: Input in vim command line mode :
Maybe there are a lot of people who are not willing to use the CLI vi/vim to write things, but when you really get used to it, its efficiency is immeasurable. The following picture, a look to understand, from now on, learning becomes no longer difficult ^_^Fill in the note:There is no search and replace in the figure, which should be used below.Top-down lookup op
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.