无法安装Ruby的sass gem

时间:2017-03-16 14:41:34

标签: ruby sass

我正在尝试安装ruby'宝石萨斯。我先运行Ruby安装,然后: 宝石安装sass。但是我收到了一个错误:

C:\ Windows \ system32> gem install sass 错误:找不到有效的宝石' sass' (> = 0)在任何存储库中 y

知道那可能是什么吗?

由于

Update.
The connad: gem sources --add https://rubygems.org/ fails:
C:\Windows\system32>gem sources --add https://rubygems.org/
Error fetching https://rubygems.org/:
Errno::ETIMEDOUT: A connection attempt failed because the connected party 
did not properly respond after a period of time, or established connection failed 
because connected host has failed to respond. - connect(2) for "api.rubygems.org" 
port 443 (https://api.rubygems.org/specs.4.8.gz)

它必须是我们用来访问Internet的代理设置。是否有可能让Ruby尊重这些设置?

更新2。

C:\Windows\system32>gem sources --add http://rubygems.org/
https://rubygems.org is recommended for security over http://rubygems.org/

Do you want to add this insecure source? [yn]  y
Error fetching http://rubygems.org/:
        Errno::ETIMEDOUT: A connection attempt failed because the connected part
y did not properly respond after a period of time, or established connection fai
led because connected host has failed to respond. - connect(2) for "api.rubygems
.org" port 80 (http://api.rubygems.org/specs.4.8.gz)

1 个答案:

答案 0 :(得分:1)

待办事项

gem sources --add https://rubygems.org/

再试一次