Skip to content

Commit

Permalink
Fix ruby-build errors with ruby 2.1.1
Browse files Browse the repository at this point in the history
Apply mislav's patch
rbenv/ruby-build#526 (comment)
against a readline bug in newer rubies. Should fix thoughtbot#219 and thoughtbot#218, and
we'll remove when a new ruby is released or if ruby-build patches this
bug itself.
  • Loading branch information
djcp committed Apr 21, 2014
1 parent f0acd78 commit 260e925
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 3 deletions.
6 changes: 5 additions & 1 deletion common-components/ruby-environment
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
ruby_version="$(curl -sSL http://ruby.thoughtbot.com/latest)"

fancy_echo "Installing Ruby $ruby_version ..."
rbenv install "$ruby_version"
if [ "$ruby_version" = "2.1.1" ]; then
curl -fsSL https://gist.github.com/mislav/a18b9d7f0dc5b9efc162.txt | rbenv install --patch 2.1.1
else
rbenv install "$ruby_version"
fi

fancy_echo "Setting $ruby_version as global default Ruby ..."
rbenv global "$ruby_version"
Expand Down
6 changes: 5 additions & 1 deletion linux
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,11 @@ fi
ruby_version="$(curl -sSL http://ruby.thoughtbot.com/latest)"

fancy_echo "Installing Ruby $ruby_version ..."
rbenv install "$ruby_version"
if [ "$ruby_version" = "2.1.1" ]; then
curl -fsSL https://gist.github.com/mislav/a18b9d7f0dc5b9efc162.txt | rbenv install --patch 2.1.1
else
rbenv install "$ruby_version"
fi

fancy_echo "Setting $ruby_version as global default Ruby ..."
rbenv global "$ruby_version"
Expand Down
6 changes: 5 additions & 1 deletion mac
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,11 @@ fancy_echo "Upgrading and linking OpenSSL ..."
ruby_version="$(curl -sSL http://ruby.thoughtbot.com/latest)"

fancy_echo "Installing Ruby $ruby_version ..."
rbenv install "$ruby_version"
if [ "$ruby_version" = "2.1.1" ]; then
curl -fsSL https://gist.github.com/mislav/a18b9d7f0dc5b9efc162.txt | rbenv install --patch 2.1.1
else
rbenv install "$ruby_version"
fi

fancy_echo "Setting $ruby_version as global default Ruby ..."
rbenv global "$ruby_version"
Expand Down

0 comments on commit 260e925

Please sign in to comment.