I\'m investigating a rails app - the prod server has two version of a specific gem installed, how can I tell which version the prod app is using?
There probably is a more direct way to find this out, but if you load up a console and require a specific version like so:
gem 'RedCloth', '3.0.4'
It will tell you what version is already activated:
=> Gem::LoadError: can't activate RedCloth (= 3.0.4, runtime) for [], already activated RedCloth-4.2.2
Try using script/about
. Your config/environment.rb
also has information about it.
In your config/environment.rb
you can specify which version of a particular gem
the application should use. However if you have multiple versions of a gem
installed on your machine and you do not specify the version, the latest version of that gem will be used by the application.
In Gemfile , there should be the answer:
gem 'rails', '4.0.0.rc1'