How to install Ruby on Rails 6 on MacOS Catalina?
In this tutorial we’ll be setting up Ruby on Rails 6.0 for development using macOS 10.15 Catalina.
This will change your terminal from Bash to ZSH. You’ll thank me later:
Read more about oh-my-zsh here.
Homebrew allows us to install packages from source on macOS.
Read more about installing Homebrew here.
We’ll be using rbenv for installing Rubies and managing Ruby versions.
We’ll then add rbenv to zshrc so that it loads every time a new session (terminal) is opened.
Install Ruby 2.7.2
We will use Ruby 2.7.2 (latest release as of November 2020) and manage our Ruby versions using rbenv.
Installing Ruby and Rails
As of November 2020, the latest Rails version is 126.96.36.199.
Create a new Rails 6 Application with PostgreSQL and React
Create the development and test databases
You can now visit http://localhost:3000 to view your new website!