安装rails时找不到Gem存储库
我的 Windows 计算机上安装了 Ruby 1.8.7 和 Ruby 1.9.2。
在我的控制台中,当我执行 ruby -v
时,它给了我 Ruby 1.8.7
现在,当我尝试时,
gem install rails -v 2.3.8
我收到此错误
ERROR: http://gems.rubyforge.org/ does not appear to be a repository
ERROR: could not find gem rails locally or in a repository
我的 RubyGems 版本显示 1.3.5,所以我尝试更新它
gem update --system
,我收到此错误
Updating RubyGems
ERROR: http://gems.rubyforge.org/ does not appear to be a repository
ERROR: While executing gem ... (Gem::RemoteFetcher::FetchError)
Errno::E10013: An attempt was made to access a socket in a way forbidden by
its access permissions. - connect(2) (http://gems.rubyforge.org/yaml)`
什么是出了问题吗?
I have Ruby 1.8.7 and Ruby 1.9.2 installed on my Windows Machine.
In my console when I do ruby -v
it gives me Ruby 1.8.7
Now when I try
gem install rails -v 2.3.8
I get this error
ERROR: http://gems.rubyforge.org/ does not appear to be a repository
ERROR: could not find gem rails locally or in a repository
My RubyGems version show 1.3.5 so I tried to update it
gem update --system
I get this error
Updating RubyGems
ERROR: http://gems.rubyforge.org/ does not appear to be a repository
ERROR: While executing gem ... (Gem::RemoteFetcher::FetchError)
Errno::E10013: An attempt was made to access a socket in a way forbidden by
its access permissions. - connect(2) (http://gems.rubyforge.org/yaml)`
What is going wrong?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
尝试一下。
这将显示您正在使用哪些来源。
这些将添加最常用的宝石来源。
Give this a try.
That will show you what sources you are using.
Those will add the most used gem sources.
我遇到了同样的错误,但是当我尝试使用 SET HTTP_PROXY 设置公司的代理时,我遇到了一个问题,因为代理使用 NTLM 验证,并且我需要指定我的 AD-Domin,这在 gem 中不起作用。我解决这个问题的方法是安装 fiddler 并启动它,然后设置
SET HTTP_PROXY=http://localhost:8888
之后我的宝石安装得像一个魅力!
I got the same error, but when I tried to set the company's proxy with SET HTTP_PROXY, I got a problem because the proxy uses NTLM validation and I needed to specify my AD-Domin which won't work wit gem. The way I got around it was installing fiddler and starting it and then setting
SET HTTP_PROXY=http://localhost:8888
afterwards my gems installed like a charm!