Search code examples
rubyrubygemsrvmwebrat

I use RVM where does webrat live? How can I find it?


How can I find /lib/webrat/core/session.rb if I use RVM?

I have no idea how to search using terminal on my OSX.

Thanks!


Solution

  • Type gem env into your terminal, look under the GEM PATHS: option. That is where your gems are stored for that version of Ruby with RVM. Go to there and you should be able to find webrat and the file you are looking for.

    For example, on my system the GEM PATH is:

    /Users/ctcherry/Developer/.rvm/gems/ruby-1.8.7-p248
    

    Leading to webrat:

    /Users/ctcherry/Developer/.rvm/gems/ruby-1.8.7-p248/gems/webrat-0.7.3
    

    And the file in question:

    /Users/ctcherry/Developer/.rvm/gems/ruby-1.8.7-p248/gems/webrat-0.7.3/lib/webrat/core/session.rb