ROR on macOS 10.12 Sierra

47 sec read

Dear Friends

A simple tutorial that can be used to install Ruby on Rails Framework on Mac Sierra.

So we are going to follow below steps

  1. Installing Homebrew
  2. Installing Ruby
  3. Installing Rails
  4. Installing sqlite3 [ default ]

Installing Homebrew

Homebrew is a required tool . It allow us to install and compile source packages from source. It comes with a very simple install script. It might ask to  install XCode CommandLine Tools, if your mac is not having them.

Write in terminal

ruby -e "$(curl -fsSL"

So now your Homebrew is installed now we proceed with other steps.

Installing Ruby

2.4.0 (Recommended)

brew install rbenv ruby-build

# Add rbenv to bash so that it loads every time you open a terminal
echo 'if which rbenv > /dev/null; then eval "$(rbenv init -)"; fi' >> ~/.bash_profile
source ~/.bash_profile

# Install Ruby
rbenv install 2.4.0
rbenv global 2.4.0
ruby -v


Installing ROR [ Ruby on Rails] framework

Recommended 5.0.1

write below command in your terminal

gem install rails -v 5.0.1

Rails is now installed. To use rails within your mac you need to reintiallize it.

rbenv rehash


Please check if rails is installed in system.

rails -v


Setting up a database 

brew install sqlite3

sqlite3 is default db.


Thanks for reading.


With due respect to used Reference