Getting Started with the Rails 3 BugMash

1.15.10 by Nathaniel Bibler

This is a short writeup to help everyone get ready for the Rails 3 BugMash. The following steps and notes were taken to help you put together a new, working Rails 3 application. Many of these steps will match Yehuda Katz’s post on getting started.

It’s important to note here that Bundler doesn’t currently work if there are spaces in your path. We’ll be submitting a patch for this shortly, but for the time being, please be aware that having no spaces in your working path is a requirement to move on.

First, clone the current rails repository using git:

$ git clone git://github.com/rails/rails.git

Then, generate a new application by typing the following (from below the cloned rails directory):

$ ruby rails/railties/bin/rails new_app_name
$ cd new_app_name

Edit the new Gemfile, adding the following to the top:

directory "/path/to/rails", :glob => "{*/,}*.gemspec"
git "git://github.com/rails/arel.git"
git "git://github.com/rails/rack.git"

Double check that you change the /path/to/rails entry to point to the full path to the git clone you made of the rails repository. Then triple check that you typed it correctly. ;) Then, bundle up!

$ gem bundle
Calculating dependencies...
Fetching git repository at: git://github.com/rails/arel.git
Fetching git repository at: git://github.com/rails/rack.git
Updating source: http://gems.rubyforge.org
Caching: abstract-1.0.0.gem
Caching: erubis-2.6.5.gem
Downloading i18n-0.3.3.gem
Downloading mail-1.6.0.gem
Caching: mime-types-1.16.gem
Downloading rack-mount-0.4.4.gem
Downloading rack-test-0.5.3.gem
Caching: rake-0.8.7.gem
Installing i18n (0.3.3)
Installing rack-test (0.5.3)
Installing rack-mount (0.4.4)
Installing abstract (1.0.0)
Installing erubis (2.6.5)
Installing mime-types (1.16)
Installing mail (1.6.0)
Installing rake (0.8.7)
Done.

Related posts:

  1. Scaling Rails – On The Edge – Part 2
  2. Census: Rails Demographics Collection
  3. Scaling Rails – On The Edge – Part 1

6 Responses to “Getting Started with the Rails 3 BugMash”

Comments

  1. Kieran P says:

    You don’t need to edit the Gemfile or manually bundle if you add –dev to the rails app generation command.

    ruby rails/railties/bin/rails new_app_name –dev

    It’ll automatically link to the clone and bundle as well.

    Also check out my rails 3 app generator: http://gist.github.com/225330

    It does what you mentioned, plus it can add scaffold data and start the server.

    http://gist.github.com/225330

Leave a Reply

* Required Fields

Additional comments powered by BackType