ruby-on-railsrailsappslearn-ruby-on-rails

Giving a 'test drive' to the app before following the book 'learn-ruby-on-rails'


I've been following Daniel Kehoe's book Learn Ruby on Rails and it is amazing. I wanted to give the finished official app a test drive before continuing to better understand where I'm heading to, however I'm not sure how to do this (given the fact that I'm just beginning the book).

I forked the "learn-rails" repo from the RailsApps GitHub account and cloned it into my Mac with the name "learn-rails-guide" (as "learn-rails" was already taken for following along). When tried to start the server, I got an error saying that I should run 'bundle install'.

I did so, hoping that the gemset created during the following along won't get messed up; however 'bundle' wasn't able to install the 'pg' gem. And I hit a road block...

Is this problem related to changing the name of the app?

Does this have something to do with the finished app being set up for production?

Am I taking the wrong approach for trying the finished app locally?

Will an app with a .ruby-gemset and a .ruby-version files mess up my current gemsets if a run bundle install?

Thanks!


Solution

  • Use $ bundle install --without production (see the book's deploy chapter). Otherwise, you'll need to install PostgreSQL locally (which can be difficult). The repo version of the app is the final version that includes gems for deploying to Heroku.

    There will be no problem with changing the name of the folder that contains the app.