I\'m using Rails 4.2 and wanted to update my Ruby version as well with rbenv.
I used Homebrew to install ruby-build and no matter how many times I try to update via
Usually, follow these steps to install a new Ruby version with rbenv
:
$ brew update
$ brew upgrade ruby-build
$ brew upgrade rbenv
Check which versions are available after updating:
$ ruby-build --definitions
Install a specific version (for example 2.1.3
) with:
$ rbenv install 2.1.3
Or if you are interested into improved support for UTF8 characters in the irb
console:
$ RUBY_CONFIGURE_OPTS=--with-readline-dir=`brew --prefix readline` rbenv install 2.1.3
After these steps I usually set the newest version as my global default:
$ rbenv global 2.1.3