April 13, 2013

Sublime Go to the definition - CTags

One of the two features I really appreciate during a development - Go to the definition. I had downloaded Ctags plugin but it did not work out of the box only because I did not know about downloading CTags (http://ctags.sourceforge.net).

Once you extract files, add a path to CTags in PATH inside Enviroment variables (for instance ;C:/Program Files/ctags). Open command line and type ctags. If an output is ctags: No files specified, we can proceed to the Sublime.

Click on any project opened in file browser there, first option should be CTags Rebuild tags. CTags creates two files in your project .tags_sorted_by_file and .tags. Use shortcut to GO TO THE DEFINITION is by default CTRL+SHIFT+. in windows. Awesome!