[Ruby on Rails (RoR)] Use brew to install Ruby on macOS with the Homebrew package manager

brew install ruby

This article is about how to use brew install Ruby on macOS with the Homebrew package manager.

Ruby versions 2.0 and above are included by default in macOS releases since at least El Capitan (10.11).

Prerequisites

Installation

1
2
# macOS
$ brew install ruby

This should install the latest Ruby version in the /usr/local/Cellar/ruby folder.

References

[1] Installing Ruby - https://www.ruby-lang.org/en/documentation/installation/

[2] Homebrew - https://brew.sh/