安装gem install sass windows 7时出错

时间:2015-02-18 16:56:03

标签: ruby sass

请帮我解决此安装错误。 首先安装ruby“Ruby 2.1.5”,然后在cmd“gem install sass”中写入但是出错了

C:\ Ruby21

  

C:> ruby​​ -v ruby​​ 2.1.5p273(2014-11-13修订版48405)[i386-mingw32]

     

C:> gem install sass错误:找不到有效的宝石'sass'(> = 0),   这是为什么:             无法从https://rubygems.org/下载数据 - Errno :: ETIMEDOUT:Se produjo un error durante el intento de conexi?n   ya que la parte conectada没有回应? adecuadamente tras un periodo   de tiempo,o bien se produjo un error e n la conexi?n establecida ya   que el host conectado no ha podido responder。 - 连接(2)for   “api.rubygems.org”端口443(https://api.rubygems.org/latest_specs.4   .8.gz)

我已经删除了代理,甚至给了我免费的ip和权限来安装“gem install sass”,但错误不断出现,但现在看来是另一个

C:\Users\usuario>gem install sass
ERROR:  Could not find a valid gem 'sass' (>= 0), here is why:
          Unable to download data from https://rubygems.org/ - SSL_connect retur
ned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (
https://api.rubygems.org/latest_specs.4.8.gz)

2 个答案:

答案 0 :(得分:12)

感谢https://www.youtube.com/user/johanricardo1108/about

,我得到了朋友

有: 宝石来源-a http://rubygems.org/ 确认然后这个: gem install sass

C:\Ruby21>gem sources -a http://rubygems.org/
https://rubygems.org is recommended for security over http://rubygems.org/

Do you want to add this insecure source? [yn]  y
http://rubygems.org/ added to sources

C:\Ruby21>gem install sass
Fetching: sass-3.4.12.gem (100%)
Successfully installed sass-3.4.12
Parsing documentation for sass-3.4.12
Installing ri documentation for sass-3.4.12
Done installing documentation for sass after 6 seconds
WARNING:  Unable to pull data from 'https://rubygems.org/': SSL_connect returned
=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (htt
ps://api.rubygems.org/latest_specs.4.8.gz)
1 gem installed

C:\Ruby21>sass -v
Sass 3.4.12 (Selective Steve)

答案 1 :(得分:0)

检查您的防火墙和网络连接。当我通过我工作的公司网络连接时遇到这个问题,因为我们有一个阻止这些的代理。

检查这些地址和端口是否在防火墙中打开:

rubygems.org 443 
github.com 443 
s3.amazonaws.com 443