Last Updated: February 25, 2016
·
1.413K
· alhafoudh

Navigate ruby source without an IDE

I had a very hard time to navigate class definitions, methods and call chains in editors like TextMate or Sublime Text 2, but now by using ctags and a ctags package for Sublime Text 2 everything changed.

How to setup Sublime Text 2: http://blog.codeclimate.com/blog/2012/06/21/sublime-text-2-for-ruby/

If you want to navigate also gems that your project is using, there is a small script that can create an index with all gems you use:

require 'bundler'
paths = Bundler.load.specs.map(&:full_gem_path)
system("ctags -R -f .gemtags #{paths.join(' ')}")

Source: https://github.com/SublimeText/CTags