I’ve gotten a Rails app from someone via heroku to modify. How can I tell, by examining the source code, what version of Rails was used to write the app?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
For Rails 3.x
It should be specified in the GEM file
For Rails 2.x – try the config/environment.rb
The file config/environment.rb may specify it e.g.
… but it is not required to.
You can take some educated guesses and try 2.3.2 or 2.3.11. Our own system uses a ton of gems and was pretty happy with 2.3.2 for at least a year.
Which Ruby Version?
A reasonable guess would be 1.8.7 as it has been around for so long. You could also try 1.9.2 but if the app has been around for more than a year, it is unlikely to be using 1.9.x – too many popular gems had problems with 1.9 until this last year or so.