VIM tags basics

This post is more of a reminder/cheatsheet for myself.
Whenever in doubt or have question check VIM :help.
For help with tags use :help tagstack

Shortcuts

  • Jump to a tag Ctrl+]
  • Jump back Ctrl+Shift+o
  • List tags g[
    Vim tags list
Advertisements

Improving PHP autocompletion in VIM

After watching VIM as PHP IDE I revisited my config, specifically pimped ctags according to articles Vim Autocompletion for PHP and Exuberant ctags with PHP in Vim

So my current $HOME/.ctags is:

--recurse
--languages=php
--langmap=php:.inc.php
--fields=+aimS
--PHP-kinds=+cfd
--exclude=.svn
--exclude=.git
--exclude=cache
--exclude=tags
--exclude=min
--exclude=\*.min.\*
--exclude=node_modules
--regex-PHP=/abstract class ([^ ]*)/\1/c/
--regex-PHP=/interface ([^ ]*)/\1/c/
--regex-PHP=/trait ([^ ]*)/\1/c/
--regex-PHP=/(public |static |abstract |protected |private )+ function +([^ \(]*)/\2/f/