Reputation: 6146
I'm currently running into some problems when trying to install the latest Ruby version using RVM. I receive the following error when using rvm install ruby-2.2.0
user$ rvm install ruby-2.2.0
Searching for binary rubies, this might take some time.
No binary rubies available for: osx/10.10/x86_64/ruby-2.2.0.
Continuing with compilation. Please read 'rvm help mount' to get more information on binary rubies.
Checking requirements for osx.
/usr/local/bin/brew: /usr/local/Library/brew.rb: /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby: bad interpreter: No such file or directory
/usr/local/bin/brew: line 21: /usr/local/Library/brew.rb: Undefined error: 0
ERROR: '/bin' is not writable - it is required for Homebrew, try 'brew doctor' to fix it!
Requirements installation failed with status: 1.
I then run brew doctor
and get the following error
/usr/local/bin/brew: /usr/local/Library/brew.rb: /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby: bad interpreter: No such file or directory
/usr/local/bin/brew: line 21: /usr/local/Library/brew.rb: Undefined error: 0
RVM gets stable commanded presented to me with this warning and I still never got the stable version
* WARNING: You have '~/.profile' file, you might want to load it,
to do that add the following line to '/Users/user/.bash_profile':
source ~/.profile
How can I fix this? I've been avoiding it for a while and really want to get it up and running. Thanks in advance
Upvotes: 3
Views: 3868
Reputation: 96
you need to do:
cd /usr/local/Library
git pull origin master
This will upgrade your homebrew and you can use brew again.
If you has problems with Permissions, try:
sudo git pull origin master
For Yosemite try this:
cd /System/Library/Frameworks/Ruby.framework/Versions
sudo ln -s Current 1.8
brew update
sudo rm 1.8
For OS X 10.8.3 Try this:
sudo chown -R $USER:admin /usr/local
cd /usr/local
git reset --hard origin/master
brew update
Mac OS X 10.10 (Yosemite) no longer ships with Ruby 1.8 (only 2.0) Update brew with git:
cd /usr/local/Library/
git branch --set-upstream-to=origin/master master
# on branch master
git pull
For the second question, edit /Users/user/.bash_profile
, then add the next sentence:
source ~/.profile
Upvotes: 8