Last Updated: February 25, 2016
·
469
· dhassler

Trouble-free rbenv and bundler

Setting up a sane ruby/bundler environment isn't hard, if you use the right tools.

  1. Install rbenv by following the instructions at https://github.com/sstephenson/rbenv#basic-github-checkout.

  2. Follow Glenn's instructions at https://gist.github.com/glv/6004197.

  3. Install rbenv-binstubs:

    git clone https://github.com/ianheggie/rbenv-binstubs.git ~/.rbenv/plugins/rbenv-binstubs

  4. Install ruby-build:

    git clone https://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build

  5. Restart your shell to apply the profile changes that rbenv made.

You will need to run bundle install in all of your projects, and maybe rbenv rehash if a new gem is installed. Use rbenv install <version> to install required versions of ruby.