Saturday, July 24th, 2021

Ruby Beginner Tutorial 3 | How To Install Ruby On MacOS

website –
Step 1 : Check if ruby is already installed
ruby -v
Step 2 : get Homebrew from
brew -v
Step 3 : Install Ruby
brew install ruby
Step 4 : Add Ruby in PATH env variable
echo ‘export PATH=”/usr/local/opt/ruby/bin:$PATH”‘ >> ~/.bash_profile

Check with following commands
ruby -v // to check ruby version
ruby -e “puts ‘Hello World'” // run a ruby program
man ruby // ruby help and documentation
gem -v // ruby gem…

Leave a Reply

Your email address will not be published. Required fields are marked *