The initial idea of writing this series of articles is to introduce how to develop software with VI/vim. However, throughout the entire series, we have little to do with software development. Basically, we are talking about Vim's usage skills and Vim's configuration.
And vimrc, VIM commands and VIM plug-ins. Therefore, after moving the article to the new site, I changed the name of this series to "VI/Vim advanced". I hope you will continue to support this series.
This is the General Directory of this series of articles. You can access all articles in this series.
I used docbook to reorganize these articles. Here you can download the HTML Version VI/Vim to use advanced
And now provides the PDF version.
Download.
- VI/Vim advanced usage: Preface
This article is a preface to this series. It describes my experiences and experiences in using vi/vim and some suggestions for beginners of VI/vim. The screenshot in this article shows my vim environment.
- VI/Vim advanced: Use session and viminfo
This article describes how to use Vim sessions and viminfo to restore the vim environment. This feature is useful if you need to recover to the same work environment frequently. You do not have to re-open the file and set your work environment.
- VI/Vim advanced: vimrc preliminary
This article briefly introduces vimrc knowledge and how to use vimrc to save Vim configurations. This article also provides some key ing (MAP) that can be used to quickly edit and load vimrc. For more vimrc applications, see other articles in this series.
- VI/Vim usage advanced: SAVE project-related configurations
This document uses the path option as an example to describe how to save and restore project-related configurations. When using vim, you may open several projects at the same time.
The functions are different. This document describes two methods to save the unique configurations of each project. One is to use a fixed Vim configuration script to save the path settings related to the project
Key ing, etc. The other is to use the session mechanism described in the previous article.
- VI/Vim advanced tutorial: Use a Tag file
This article describes how to use exuberant ctags to generate tag files and how to use the Tag file in VIM to perform jump and search operations. The format of the Tag file is also briefly introduced. In the lookupfile plug-in introduced later, the Tag file is used to conveniently find and open the file.
- VI/Vim advanced: Use the taglist plug-in
This article describes how to use the taglist plug-in (plugin) to view tags in a program, and introduces the configuration and usage of the taglist plug-in. Use the taglist plug-in
The exuberant ctags program generates a Tag file and provides a tag window like source insight, allowing you to easily jump to the location of tags such as functions and variables.
- VI/Vim advanced usage: file browsing and buffer browsing
This section describes how to browse files in vim and how to view the currently opened buffer. With the netrw plug-in, you can easily browse various directories in vim and open specified files without switching
File browser or shell; of course, the function of the netrw plug-in is not limited to this. Using the bufexplorer plug-in, you can easily view the opened Buffer
(Buffer) in the buffer range. The winmanager plug-in is introduced at the end of this Article. With this plug-in, you can use the netrw plug-in, bufexplorer plug-in, and
Integrate the taglist plug-in to make Vim look more like an integrated development environment (IDE ).
- VI/Vim use advanced: lookupfile plug-in
If you are developing a large project, the lookupfile plug-in is essential when you want to search for or edit a specified file in a large number of files. You can use it to quickly find project files
Find the specified file in the buffer and browse the specified directory. You can even use a regular expression (RegEx) when searching. This is a life-saving method when you only remember some file names or directory names.
VI/Vim advanced: Enable file type detection
One of the most attractive aspects of VIM is that it supports an infinite number of file types and can be expanded at will. This article describes how to enable the file type detection function and how to use a file type-based plug-in.
(Filetype
Plugin ). With the file type detection function, we can define different map and set different options for different types of files, syntax highlighting (after
This document will be introduced later )... You can implement any function you want.
- VI/Vim advanced tutorial: getting eye-catching
Vim is not only black. On the contrary, it provides a flexible mechanism to allow users to customize colors. Vim running on the terminal can only use several fixed colors due to the limitations of the terminal itself. However, for gvim, you can call out any color based on your preferences. This article describes the syntax highlighting function of vim.
- VI/Vim advanced application: A Tool for programmers-cs.pdf
The previous article introduced how to use the Tag file generated by ctags to jump to the tag definition. However, if you want to find out where the function is called or where the tag appears, ctags will not
More powerful cscope is required. This article describes how to use csinsight. With csinsight, you can throw source insight to one side.
- VI/Vim advanced tutorial: quick fix
Vim is developed by a programmer and used by more programmers. Therefore, Vim's strong support for developers is understandable. The introduction of quickfix mode is an example.
Quickfix mode is a way to accelerate your development, so that you do not have to leave vim, you can quickly complete "edit-compile-modify" your program. It is not only useful to developers, as long
Your work is similar to "edit-compile-modify", which greatly simplifies your work.
- VI/Vim advanced: Smart completion
Those who have used source insight must be impressed with its auto-completion function. In many integrated development environments, it also supports auto-completion. Vim, as an excellent editor, is indispensable. This article describes how to complete the Omni of vim. In the next article, we will introduce other completion methods.
- VI/Vim advanced: Automatic completion
This article continues to introduce the complete function of vim. As a general editor, the complete function implemented by VIM is not only limited to program completion, it can complete the file name, complete according to the dictionary, according to the local slow
The dashboard or other buffer-like content is supplemented, and File Syntax is supplemented. It even allows users to write their own functions to implement customized completion. This article briefly introduces these methods.
- VI/Vim advanced usage: Mobile, as shown in the following figure (1)
Vim provides many mobile methods, but we don't need to master all these commands. We just need to know the commands that best suit us. This article describes some of the most commonly used mobile commands. In the next article, we will introduce more advanced mobile methods.
- VI/Vim advanced usage: Mobile, mobile, and flying (2)
This article describes how to move data in Vim, including how to use a jump table (jump-motions), how to use a mark, how to use a fold, and how to move data in a program.
- VI/Vim advanced: Use GDB for debugging in vim-use vimgdb
This article describes how to use the vimgdb patch to debug the program using GDB in Vim, and also describes the compilation method of vim. However, VIM is only an editor rather than an integrated development environment (IDE), so it has limited support for debugging.
- VI/Vim usage advanced: FAQs during vimgdb debugging and Solutions
In the previous article, I introduced how to use the vimgdb patch to debug programs in VIM/gvim. Later, some readers gave feedback about the problems they encountered. This article summarizes common problems and solutions.
- VI/Vim advanced: Use GDB for debugging in gvim-use pyclewn
This article describes how to use pyclewn to debug programs in gvim using GDB. Pyclewn is another file written by vimgdb. It enables gvim to be integrated and debugged with GDB on Unix/Linux and Windows.
- VI/Vim use advanced: Problems Encountered during vim compilation and Solutions
This article mainly introduces problems encountered in VIM compilation and solutions. This article describes how to view config. log to find out the cause of configuration failure. Some netizens failed to compile gvim in graphical mode. You can refer to this article to solve the problem.
- VI/Vim advanced tutorial: Using copy/paste in VIM
To be continued
- VI/Vim use advanced: Map your vim buttons
To be continued
- VI/Vim advanced: Use the abbreviated Vim Function
To be continued
- VI/Vim advanced: Powerful Automatic Command (autocmd)
To be continued
- Other topics you are interested in
To be continued