Ruby - Local Environment Setup Mac
📚 tutorials

Ruby - Local Environment Setup Mac

1 min read 116 words
1 min read
ShareWhatsAppPost on X
  • 1To install Ruby on a Mac, you need to download and configure OpenSSL first.
  • 2Use RVM to manage Ruby versions and install the desired version with OpenSSL support.
  • 3After installing Ruby, use Bundler to manage your application's dependencies effectively.

AI-generated summary · May not capture all nuances

Key Insight
AskGif

"To install Ruby on a Mac, you need to download and configure OpenSSL first."

Ruby - Local Environment Setup Mac

In this post, we’re going to show you how to install Ruby on your Mac. Along the way, we’ll learn about the steps involved and various bits of knowledge required to get up and going.

Here are the Mac installation steps.

To install ruby with rails:

- wget https://ftp.openssl.org/source/old/1.0.1/openssl-1.0.1i.tar.gz

- tar xvf openssl-1.0.1i.tar.gz

- cd openssl-1.0.1i/

- rm -rf ~/.rvm/usr

- mkdir -p ~/.rvm/usr/ssl

- ./Configure darwin64-x86_64-cc --prefix=$HOME/.rvm/usr --openssldir=$HOME/.rvm/usr/ssl

- make

- make install

- Set the following in $HOME/.rvmrc

export CFLAGS="-O2 -arch x86_64"

export LDFLAGS="-L$HOME/.rvm/usr/lib -L/opt/local/lib"

export CPPFLAGS="-I$HOME/.rvm/usr/include -I/opt/local/include"

- rvm reinstall 2.3.8 --with-openssl-dir=$HOME/.rvm/usr/ #here I am installing 2.3.8 you can give whatever version you want

- gem install bundler -v 1.17.3

- bundle install

Enjoyed this article?

Share it with someone who'd find it useful.

ShareWhatsAppPost on X

AskGif

Published on 11 May 2020 · 1 min read · 116 words

Part of AskGif Blog · tutorials

You might also like

Ruby - Local Environment Setup Mac | AskGif Blog