Skip to content

Instantly share code, notes, and snippets.

@tbeseda
Created November 18, 2011 00:47
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tbeseda/1375134 to your computer and use it in GitHub Desktop.
Save tbeseda/1375134 to your computer and use it in GitHub Desktop.
Basic rbenv usage

(specify your favorite flavor if you're not ready for 1.9.3):

$ rbenv install 1.9.3-p0

to rebuild rbenv's shims, when you install a new system system gem with a binary (like rake):

$ rbenv rehash

set a global version of Ruby to be used (instead of your system Ruby):

$ rbenv global 1.9.3-p0

set the version of Ruby for a specific project directory by creating a .rbenv-version file (which we ignored earlier):

$ rbenv local 1.9.2-p290

to get bundler installed into your current Ruby's gemset:

$ gem install bundler

Run bundle in your project directory will now install the gems in your Gemfile directly into your project in vender/bundle.

Finally, to start up your app in the context of your bundled gems:

$ bundle exec rails s
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment