-
-
Save turadg/5092528 to your computer and use it in GitHub Desktop.
Install Ruby 2.0 with Readline and latest OpenSSL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env sh | |
brew update | |
# upgrade any that were already installed | |
brew upgrade rbenv ruby-build readline openssl | |
# install what's missing | |
brew install rbenv ruby-build readline openssl | |
# build with Readline and OpenSSL | |
env RUBY_CONFIGURE_OPTS=--with-openssl-dir=`brew --prefix openssl` CONFIGURE_OPTS=--with-readline-dir=`brew --prefix readline` rbenv install 2.0.0-p0 | |
# test the SSL | |
ruby -rnet/https -e "Net::HTTP.get URI('https://github.com')" | |
# If the above fails, follow this solution | |
if [ $? -eq 0 ] | |
then echo 'HTTPS working' | |
else open http://railsapps.github.com/openssl-certificate-verify-failed.html | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Trying with ruby-2.0.0-p247 did not work.