Reputation: 635
We have ruby with version ruby 2.0.0p648 (2015-12-16 revision 53162) [universal.x86_64-darwin15]. We need uninstall ruby and install again. So we tried like this
Anshuls-Mac-mini-2:~ pankajthakur$ whereis ruby
/usr/bin/ruby
Anshuls-Mac-mini-2:~ pankajthakur$ rm -f /usr/bin/ruby
rm: /usr/bin/ruby: Permission denied
We need re-install in other location. Please guide to us.
My current MAC os Version 10.11.5 (El Capitan)
Upvotes: 6
Views: 26511
Reputation: 1347
I got exactly the same version on one of my computer and I used Homebrew to install the latest version and overwrite the old one.
In your terminal run brew install ruby
to download the latest version and then run brew link --overwrite ruby
to replace your version of Ruby.
You can also use rbenv
to install and run different version of Ruby on your computer brew install rbenv
.
EDIT: I think rbenv
might be the easiest way to manage your Ruby environment.
Upvotes: 1