So previously when we were setting up Rails we installed Ruby, so in this post we are going to go over how you would update your Ruby version.
As you may remember we are using rbenv
to manage our Ruby versions. And this was installed on top of Homebrew.
The following lines are used to install Ruby 2.7.0 (check ruby-lang.org for the latest version) and set it as your default Ruby version:
$ brew update
$ brew upgrade ruby-build
$ rbenv install 2.7.0
$ rbenv global 2.7.0
$ ruby -v
Not as bad as you thought? Well why make things harder than they need to be. Anyway, as you see we ran ruby -v
just to make sure we are now running the latest Ruby version.