This is provided as a quick way to get up and running with rails. In
the future, you'll probably want to explore rails new
and setup your
favorite gem dependencies in the Gemfile
.
We're assuming that you have ruby installed. If you don't have it installed on your machine, see How Should I prepare for my first Ruby lesson?
You can also create a free nitrous.io instance and follow these same instructions. The only difference is that you won't be going to localhost to view the site, but rather you'll have to click Preview and choose to share on port 3000.
If you've set up git, then simply clone the repository:
bash$ git clone https://github.com/rails-school/starter.git
If you haven't setup git, or don't know what that is, you can download the starter app zip file and then unzip it into a place that will be easy to get to (like your home directory, or a subdirectory off of your home directory).
-
Open up a terminal and navigate to where you installed the codebase. For example,
bash$ cd ~/starter
-
Install all the dependencies listed in the
Gemfile
bash$ bundle install
-
Create the initial database
bash$ rake db:create bash$ rake db:migrate
-
Launch the server
bash$ rails server
-
If everything went well, navigate to localhost:3000