I installed rbenv via Homebrew on a OS X 10.9.3 MacBook Pro.
我在一台OS X 10.9.3 MacBook Pro笔记本电脑上安装了rbenv。
I did:
我做了:
brew update
brew upgrade rbenv ruby-build
According to rbenv install --list
on my laptop Ruby 2.1.0-dev is the latest.
根据rbenv安装——我的笔记本电脑Ruby 2.1.0-dev是最新的。
Does anyone know what this is about? I'm going to guess it's a 10.9.3 problem.
有人知道这是怎么回事吗?我猜这是一个10。3的问题。
10 个解决方案
#1
78
Both rbenv and ruby-build are generally installed from Github by cloning; That's how the authors recommend we install it.
rbenv和ruby-build通常都是从Github上克隆而来的;这就是作者建议我们安装它的原因。
git clone https://github.com/sstephenson/rbenv.git ~/.rbenv
git clone https://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build
If you didn't do it that way I'd recommend that method. Then, you can simply do:
如果你不这样做,我建议你采用这种方法。然后,你可以简单地做:
cd ~/.rbenv
git pull
cd plugins/ruby-build
git pull
If you have several plugins use:
如果你有几个插件使用:
cd plugins
for i in *
do
cd $i
git pull
cd -
done
I update every couple weeks just to pull in the latest fixes/changes.
我每隔几周更新一次,只是为了获取最新的补丁/更改。
#2
47
I faced the same issue. I got the latest by running the following command:
我面临着同样的问题。我通过运行以下命令获得了最新消息:
brew upgrade --HEAD ruby-build
#3
16
I had this issue on OS X 10.8.5 (so don't think OS related). I had tried updating rbenv & ruby-build via brew. 2.1.0-dev was still latest build available.
我在OS X 10.8.5上有这个问题(所以不要认为操作系统是相关的)。我曾尝试通过brew升级rbenv和ruby。2.1.0-dev仍然是最新的版本。
I had to force uninstall and re-install ruby-build via brew to fix the issue.
我不得不强制卸载和重新安装通过brew来修复这个问题。
brew uninstall ruby-build --force
brew install ruby-build
#4
10
I had the same issue. Even after running
我有同样的问题。即使在运行
brew upgrade rbenv ruby-build
I still didn't get ruby-2.1.2 on the available list. Following how to update list of available ruby versions on linux, I updated ruby-build through the following commands
在可用的列表上,我仍然没有得到ruby-2.1.2。在如何更新linux上可用ruby版本的列表之后,我通过以下命令更新了ruby-build。
cd ~/.rbenv/plugins/ruby-build
git pull
(I'm using OS X 10.9.4 MacBook Air)
(我使用的是OS X 10.9.4 MacBook Air)
#5
7
This happened to me today. "rbenv install -l' displays outdated list while "ruby-build --definitions" returns the correct list. The problem is fixed by executing following command:
这事今天发生在我身上。“rbenv安装-l”显示过时的列表,而“ruby-build—定义”返回正确的列表。通过执行以下命令来解决这个问题:
rm -Rf ~/.rbenv/plugins/ruby-build
It seems there is an outdated version of ruby-build under ~/.rbenv/plugins. Not sure when it got generated.
似乎在~/.rbenv/插件的下面有一个过时的ruby-build版本。不确定它什么时候生成的。
#6
5
The selected answer will work fine, but the issue may have simply been caused by homebrew not having an up-to-date formula for ruby-build at the time. As of this posting, the appropriate ruby-build formula has been put into the latest version of homebrew. So running:
选择的答案会很好,但问题可能仅仅是由于自制的,没有最新的配方。在这篇文章中,最新版本的homebrew已经推出了合适的ruby-build公式。所以运行:
$ brew update
酿造美元更新
should get you version needed to get the latest ruby. Then, running rbenv install --list
again should list 2.1.2 (and others).
应该得到您需要的版本来获得最新的ruby。然后,运行rbenv安装—再次列出2.1.2(和其他)。
So if anyone sees this later on, hopefully you can avoid having to maintain the individual repositories if you'd rather use homebrew for package management.
因此,如果以后有人看到这个,希望您可以避免维护单个存储库,如果您宁愿使用homebrew进行包管理。
#7
3
This link gives a good explanation of the two available options.
这个链接可以很好地解释两个可用选项。
If you installed rbenv from the git repository: $ cd ~/.rbenv/plugins/ruby-build $ git pull
如果您从git存储库中安装了rbenv: $ cd ~/。rbenv /插件/ ruby-build git把美元
If you used Homebrew on OSX to install rbenv: $ brew update $ brew upgrade ruby-build
(Also running brew doctor
might give you the exact solution.)
如果你在OSX上使用Homebrew来安装rbenv: $ brew升级$ brew升级ruby-build(同时运行brew医生可能会提供精确的解决方案)。
And if you have permission denied errors, this is my addition: $ sudo chown -R $USER /usr/local; brew update $ sudo chown -R $USER /usr/local; brew upgrade ruby-build
如果您有权限否认错误,这是我的新增:$ sudo chown -R $USER /usr/local;brew更新$ sudo chown -R $USER /usr/local;酿造升级ruby-build
Then you'll be able to install the recent versions. $ rbenv install --list $ rbenv install 2.1.2
然后您将能够安装最新版本。$ rbenv安装——列表$ rbenv安装2.1.2。
#8
0
I've just updated ruby-build and ruby-install to latest versions and both have the latest ruby 2.1.2
我刚刚更新了ruby-build和ruby-install的最新版本,并且都有最新的ruby 2.1.2。
Probably rbenv doing something nasty.
可能是rbenv干了些坏事。
#9
0
Following all the above, on OSX 10.11 it still wouldn't list the latest versions. What I did below worked for me- I removed the dir, re-installed from brew then I had to link in brew like this:
在osx10.11上面,仍然没有列出最新的版本。我所做的工作是为我工作的——我删除了目录,重新安装了brew,然后我必须链接到这样的brew:
$ brew uninstall ruby-build --force
$ rm -Rf ~/.rbenv/plugins/ruby-build
and then
然后
$ brew install ruby-build
$ brew link --overwrite ruby-build
and then I saw the most recent versions to build.
然后我看到了最新版本的版本。
#10
0
cd /home/[user]/.rbenv/plugins/ruby-build && git pull && cd -
cd /home/[用户]/。rbenv/plugins/ruby-build && && & cd -。
Don't forget to replace [user] with your user
不要忘记用你的用户替换[用户]。
#1
78
Both rbenv and ruby-build are generally installed from Github by cloning; That's how the authors recommend we install it.
rbenv和ruby-build通常都是从Github上克隆而来的;这就是作者建议我们安装它的原因。
git clone https://github.com/sstephenson/rbenv.git ~/.rbenv
git clone https://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build
If you didn't do it that way I'd recommend that method. Then, you can simply do:
如果你不这样做,我建议你采用这种方法。然后,你可以简单地做:
cd ~/.rbenv
git pull
cd plugins/ruby-build
git pull
If you have several plugins use:
如果你有几个插件使用:
cd plugins
for i in *
do
cd $i
git pull
cd -
done
I update every couple weeks just to pull in the latest fixes/changes.
我每隔几周更新一次,只是为了获取最新的补丁/更改。
#2
47
I faced the same issue. I got the latest by running the following command:
我面临着同样的问题。我通过运行以下命令获得了最新消息:
brew upgrade --HEAD ruby-build
#3
16
I had this issue on OS X 10.8.5 (so don't think OS related). I had tried updating rbenv & ruby-build via brew. 2.1.0-dev was still latest build available.
我在OS X 10.8.5上有这个问题(所以不要认为操作系统是相关的)。我曾尝试通过brew升级rbenv和ruby。2.1.0-dev仍然是最新的版本。
I had to force uninstall and re-install ruby-build via brew to fix the issue.
我不得不强制卸载和重新安装通过brew来修复这个问题。
brew uninstall ruby-build --force
brew install ruby-build
#4
10
I had the same issue. Even after running
我有同样的问题。即使在运行
brew upgrade rbenv ruby-build
I still didn't get ruby-2.1.2 on the available list. Following how to update list of available ruby versions on linux, I updated ruby-build through the following commands
在可用的列表上,我仍然没有得到ruby-2.1.2。在如何更新linux上可用ruby版本的列表之后,我通过以下命令更新了ruby-build。
cd ~/.rbenv/plugins/ruby-build
git pull
(I'm using OS X 10.9.4 MacBook Air)
(我使用的是OS X 10.9.4 MacBook Air)
#5
7
This happened to me today. "rbenv install -l' displays outdated list while "ruby-build --definitions" returns the correct list. The problem is fixed by executing following command:
这事今天发生在我身上。“rbenv安装-l”显示过时的列表,而“ruby-build—定义”返回正确的列表。通过执行以下命令来解决这个问题:
rm -Rf ~/.rbenv/plugins/ruby-build
It seems there is an outdated version of ruby-build under ~/.rbenv/plugins. Not sure when it got generated.
似乎在~/.rbenv/插件的下面有一个过时的ruby-build版本。不确定它什么时候生成的。
#6
5
The selected answer will work fine, but the issue may have simply been caused by homebrew not having an up-to-date formula for ruby-build at the time. As of this posting, the appropriate ruby-build formula has been put into the latest version of homebrew. So running:
选择的答案会很好,但问题可能仅仅是由于自制的,没有最新的配方。在这篇文章中,最新版本的homebrew已经推出了合适的ruby-build公式。所以运行:
$ brew update
酿造美元更新
should get you version needed to get the latest ruby. Then, running rbenv install --list
again should list 2.1.2 (and others).
应该得到您需要的版本来获得最新的ruby。然后,运行rbenv安装—再次列出2.1.2(和其他)。
So if anyone sees this later on, hopefully you can avoid having to maintain the individual repositories if you'd rather use homebrew for package management.
因此,如果以后有人看到这个,希望您可以避免维护单个存储库,如果您宁愿使用homebrew进行包管理。
#7
3
This link gives a good explanation of the two available options.
这个链接可以很好地解释两个可用选项。
If you installed rbenv from the git repository: $ cd ~/.rbenv/plugins/ruby-build $ git pull
如果您从git存储库中安装了rbenv: $ cd ~/。rbenv /插件/ ruby-build git把美元
If you used Homebrew on OSX to install rbenv: $ brew update $ brew upgrade ruby-build
(Also running brew doctor
might give you the exact solution.)
如果你在OSX上使用Homebrew来安装rbenv: $ brew升级$ brew升级ruby-build(同时运行brew医生可能会提供精确的解决方案)。
And if you have permission denied errors, this is my addition: $ sudo chown -R $USER /usr/local; brew update $ sudo chown -R $USER /usr/local; brew upgrade ruby-build
如果您有权限否认错误,这是我的新增:$ sudo chown -R $USER /usr/local;brew更新$ sudo chown -R $USER /usr/local;酿造升级ruby-build
Then you'll be able to install the recent versions. $ rbenv install --list $ rbenv install 2.1.2
然后您将能够安装最新版本。$ rbenv安装——列表$ rbenv安装2.1.2。
#8
0
I've just updated ruby-build and ruby-install to latest versions and both have the latest ruby 2.1.2
我刚刚更新了ruby-build和ruby-install的最新版本,并且都有最新的ruby 2.1.2。
Probably rbenv doing something nasty.
可能是rbenv干了些坏事。
#9
0
Following all the above, on OSX 10.11 it still wouldn't list the latest versions. What I did below worked for me- I removed the dir, re-installed from brew then I had to link in brew like this:
在osx10.11上面,仍然没有列出最新的版本。我所做的工作是为我工作的——我删除了目录,重新安装了brew,然后我必须链接到这样的brew:
$ brew uninstall ruby-build --force
$ rm -Rf ~/.rbenv/plugins/ruby-build
and then
然后
$ brew install ruby-build
$ brew link --overwrite ruby-build
and then I saw the most recent versions to build.
然后我看到了最新版本的版本。
#10
0
cd /home/[user]/.rbenv/plugins/ruby-build && git pull && cd -
cd /home/[用户]/。rbenv/plugins/ruby-build && && & cd -。
Don't forget to replace [user] with your user
不要忘记用你的用户替换[用户]。