Talk Vim together (15th back: ctags of Vim plug-in), vimctags
Hello, everyone. You are welcome to join in to hear the story of Zhang huiti: Vim. The configuration in the Vim plug-in was introduced in the last time.
Set files. In this case, let's continue with the Vim plug-in. In this case, the Vim plug-in is called ctags. Okay, let's say that,
When you leave the rest of your time, your words will go right. Let's talk Vim together!
Look, we are talking about the plug-in Vim: ctags. Ctags is a tool or application software. It can be implemented through plug-ins
Run in Vim. "What is ctags?" according to the official question, the ctags are mainly used to generate tags with tags.
You can use the tags label to quickly find what you want. A metaphor: when we travel to a city, we will definitely see
Map of the city, and then find the scenic spots we want to visit through the map. Ctags is like a city map, through which we can find the path
Function or variable in sequence. This achieves twice the result with half the effort when reading the code.
Ctags are not installed in the Mint by default, so we need to install them manually. The installation method is as follows:
Run the command: which ctags to check whether the ctags is installed in the system.
If so, ctags is not installed in the system.
Run the command apt-get install ctags to install ctags. After running the command, the following result is displayed:
Reading the package list... complete
Analyzing the dependency tree of the software package
Reading status information... complete
Note, selecting 'exuberant-ctags 'instead of 'ctags'
The following [new] software packages will be installed:
Exuberant-ctags
0 software packages are upgraded, 1 new software package is installed, 0 software packages are to be uninstalled, and 388 software packages are not upgraded.
Download the 116 kB software package.
After decompression, 308 kB of extra space will be consumed.
Get: 1 http://archive.ubuntu.com/ubuntu/ trusty-updates/main exuberant-ctags i386. 9 ~ Svn20110310-7ubuntu0.1 [116 kB]
Download 116 kB, which takes 2 seconds (47.4 kB/s)
Selecting previusly unselected package exuberant-ctags.
(Reading the database... the system currently has 158086 files and directories installed .)
Preparing to unpack.../exuberant-ctags_1 % 3a5. 9 ~ Svn20110310-7ubuntu0.1_i386.deb...
Unpacking exuberant-ctags (. 9 ~ Svn20110310-7ubuntu0.1 )...
Processing triggers for man-db (2.6.7.1-1ubuntu1 )...
Setting exuberant-ctags (. 9 ~ Svn20110310-7ubuntu0.1 )...
Update-alternatives: using/usr/bin/ctags-exuberant to provide/usr/bin/ctags (ctags) in automatic mode
Update-alternatives: using/usr/bin/ctags-exuberant to provide/usr/bin/etags (etags) in automatic mode
The result shows that the ctags has been successfully installed in the system.
Finally, check whether the installation is successful. The method is the same as in step 1: which ctags
Run the following command to obtain the result:/usr/bin/ctags. This indicates that ctags has been successfully installed in the system.
Add the following configuration information to the Vim configuration file (. vimrc): set tags = tags, set tags + =./tags
This configuration allows vim to find the tags file in the current directory at startup.
We have installed the Vim plug-in: ctags through the above method. I am already OK, Are you OK? O_O
For more information, see the Vim plug-in ctags. In later chapters, we will also talk about other Vim plug-ins.
. What plug-ins will be available in the future? In addition, the next loop is decomposed.