ProjectCTags : Generates CTAGS for versioned projects without the need to maintain project file
| script karma
Downloaded by 422
Comments, bugs, improvements
script versions (upload new version)
|ProjectCTags is a plugin that enables you to generate CTags for a project which is under version control. These tags can then be used to Eclipse-like "Jump-To-Definition" or autocompletion of source code. Currently the plugin recognizes source code projects which are versioned with git, CVS and SVN version control systems. This plugin eases the task of generating up-to-date tag files. For people who like to maintain vim project files (Personally I do not like to do that, I just want tags for everything in my project folders), vimscript #3221 might be more appropriate. Once you have generated the tags you can use them in the following ways:
* Jump to definition of the tag (if it is located in your project) under the cursor with Ctrl-]
* Autocomplete C/C++ source code with vimscript #1520 (See vimscript #1643 for intelligent <Tab> key completion)
When you have opened a file, the plugin may either automatically update the corresponding tagfiles or it does this on your command (optional). It creates two tagfiles: One in the current folder, which contains detailed informations such as tags for local variables, and one tagfile in the project folder, which contains a less detailed overview of the globally visible tags in all source files in the versioned tree. By default it creates tags in the proper format for vimscript #1520.
The generated tags will only cover the code that is contained in your project! STL code etc is not included. If you want autocompletion for STL code you must download vimscript #2358 and insert the following into your .vimrc
set tags += "path/to/stl_tag_file"
If you have questions or suggestions about/for the plugin, feel free to contact me. And of course, if you like the plugin, vote for it in the box below :-)
|Just move projectCTags.vim to ~/.vim/plugin. The plugin requires CTags to be installed (http://ctags.sourceforge.net/). If CTags is not in your $PATH environment variable, then you must specify the path to the CTags executable by putting
let g:projectCTagsCTagsExe = "path/to/ctags"
into your .vimrc file. To generate and set the CTags you can then use :GenerateProjectCTags( "Tag Setting Name", "ctags options" ). It is useful to map this to a key like
map <F3> :call GenerateProjectCTags( "Standard", "" )<CR>
map <F4> :call GenerateProjectCTags( "Exclude Stuff", "--languages=C,C++ --exclude=folder1 --exclude=folder2" )<CR>
For further options, see the "projectCTags.vim" file. They are all listed and documented at the top of the file. A useful option, which should be set inside the ~/.vimrc, is:
let g:projectCTagsAutogenerateTags = 1
This will let ProjectCTags automatically regenerate the tag files when you open a C/C++ file if you have already created the tags once manually by invoking :GenerateProjectCTags() before. This will then re-use the options (second parameter of GenerateProjectCTags) which were used last time inside the project. The options are stored in a ".tags_options" file in the project folder.
Click on the package to download.
ip used for rating: 184.108.40.206