在这几天在电脑上安装compass一直报错,很无语。因为安装的ruby和sass都没有问题,虽然是很久之前安装的。
 
sass
# 更新sass
gem update sass
 
# 检查sass version
sass -v
 
gem
#检查gem
gem -v
 
#更新系统gem
gem update --system
//在这里报错
 
compass
#检查compass
compass -v
//报错,compass不是内部命令
 
#安装compass
gem install compass
//报错
 
报错的内容:
Error fetching https://ruby.taobao.org/:        SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (https://rubygems-china.oss-cn-hangzhou.aliyuncs.com/specs.4.8.gz)
 
解决方法:
# 检查gem source
gem sources
# 或者
gem sources -l
 
# 打印值
*** CURRENT SOURCES ***
 
如果你的打印值也是https://rubygems.org/,那么就一定装不上compass.我们用国内镜像解决这个问题:
很早之前用,也是网上很多都给出的解决方案,用的是淘宝的 https://ruby.taobao.org/镜像,但是现在rubygems镜像的管理工作交给Ruby China 负责,以便能有更多的社区爱好者参与进来,保持持续发展。
所以现在用的本地镜像:https://gems.ruby-china.org/来解决
# 检查本地 gem sources
gem sources -l
 
# 打印值
*** CURRENT SOURCES ***
 
# 移除
gem sources -r https://rubygems.org/
# 打印
*** CURRENT SOURCES ***
 
# 添加 
gem sources -r https://gems.ruby-china.org/
//1.如果没有报错,用 gem sources -l 的打印值是 https://gems.ruby-china.org/,那么恭喜你,可以顺利安装compass了
//2.报错,可以换网络试一下
 
我恰好碰上的就是报错的情况,然后换了网络重新执行了一下添加这一步:
# 添加
 
//依然报错,然后我是这么解决的,把https换成http:
# 添加
//没有报错
//看来 http 可以避免 SSL的问题
 
# 检查 gem sources
gem sources -l
# 打印
*** CURRENT SOURCES ***
 
这样就没有问题,记得 gem sources -l 的值只能保留一个。
然后更新安装什么的:
# 更新
gem uptate --system
# 检查
gem -v
 
# 安装
gem install compass
# 检查
compass -v
 
然后安装更新都非常6,然后我们就可以使用 compass 了。

ruby镜像报错,compass安装报错的更多相关文章

  1. Ruby与sass 与compass安装

     Ruby安装 windows平台下使用Rubyinstaller安装 1) 下载Rubyinstaller 2) 安装Rubyinstaller 记得勾选 add ruby executables ...

  2. 安装Tensorflow过程pip安装报错:is not a supported wheel on this platform

    安装Tensorflow过程pip安装报错:is not a supported wheel on this platform 通过pip安装wheel镜像时,安装指令为: pip install - ...

  3. pip install cv2 安装报错

    pip install cv2 安装报错是一个常见现象: ERROR: Could not find a version that satisfies the requirement cv2 (fro ...

  4. MSSQL 2012安装报错之0x858C001B

    之前安装 Microsoft Sql Server 2012 R2 的时候总是报这样的错误: SQL Server Setup has encountered the following error: ...

  5. mydumper 安装报错处理

    mydumper 官网:https://launchpad.net/mydumper 下载之后,安装报错: [root@localhost local]# cd mydumper-0.6.2 [roo ...

  6. linux -小记(2)问题:yum 安装报错"Another app is currently holding the yum lock; waiting for it to exit... ...: yum Memory : 26 M RSS (868 MB VSZ) Started: Wed Oct 26 22:48:24 2016 - 0"

    yum 安装报错 "Another app is currently holding the yum lock; waiting for it to exit... The other ap ...

  7. office2010安装报错

    有没有童鞋,在第一次安装office 2010的时候,中途不管是何原因导致中断或者未安装成功的 然后从第二次开始就一直安装报错??? 哈哈,我最近就遇到了 其他很简单,网上有很多方法,也有很多步骤,包 ...

  8. yum安装报错有冲突file /usr/lib64/php/modules/fileinfo.so conflicts between

    yum安装报错有冲突file /usr/lib64/php/modules/fileinfo.so conflicts between attempted installs of php-pecl-f ...

  9. Android Studio 首次安装报错 Java.lang.RuntimeException:java.lang.NullPointerException...错

    下次安装报:Java.lang.RuntimeException: java.lang.NullPointerException......错 只需在文件..\Android Studio\bin\i ...

随机推荐

  1. Laravel --- 【转】安装调试利器 Laravel Debugbar

    [转]http://www.tuicool.com/articles/qYfmmur 1.简介 Laravel Debugbar 在 Laravel 5 中集成了 PHP Debug Bar ,用于显 ...

  2. window系统谷歌浏览器百度搜索框光标不能输入并且不显示光标----自制bug以及解决

    --------------------bug无处不在------------------------- 今天在搞代码的时候,保存文件无意中犯了个致命错误,文件名称写入非法字符,可能与Windows系 ...

  3. 最全java多线程总结3——了解阻塞队列和线程安全集合不

      看了前两篇你肯定已经理解了 java 并发编程的低层构建.然而,在实际编程中,应该经可能的远离低层结构,毕竟太底层的东西用起来是比较容易出错的,特别是并发编程,既难以调试,也难以发现问题,我们还是 ...

  4. Codeforces Round #563 (Div. 2)B

    B.Ehab Is an Odd Person 题目链接:http://codeforces.com/contest/1174/problem/B 题目 You’re given an array a ...

  5. 8天入门docker系列 —— 第七天 让你的container实现跨主机访问

    当你有若干个容器之后,你可能就希望实现容器的跨机部署访问了,比如aspnetcore在一台host上,mysql在另外一个host上,如果要实现这样的功能,需要你借助 docker自带的overlay ...

  6. Adding Cues (线索、提示) to Binary Feature Descriptors for Visual Place Recognition 论文阅读

    对于有想法改良描述子却无从下手的同学还是比较有帮助的. Abstract 在这个文章中我们提出了一种嵌入continues and selector(感觉就是analogue和digital的区别)线 ...

  7. HDU 1565:方格取数(1)(最大点权独立集)***

    http://acm.hdu.edu.cn/showproblem.php?pid=1565 题意:中文. 思路:一个棋盘,要使得相邻的点不能同时选,问最大和是多少,这个问题就是最大点权独立集. 可以 ...

  8. python 中的__name__ == "__main__"(转)

    有句话经典的概括了这段代码的意义: “Make a script both importable and executable” 意思就是说让你写的脚本模块既可以导入到别的模块中用,另外该模块自己也可 ...

  9. c++学习书籍推荐《C++程序设计语言(特别版)》下载

    百度云及其他网盘下载地址:点我 编辑推荐 <C++程序设计语言(特别版•十周年中文纪念版)>编辑推荐:十周年纪念版,体味C++语言的精妙与魅力,享受与大师的心灵对话.1979年,Biarn ...

  10. C语言学习书籍推荐《Practical C++ Programming》下载

    下载链接 :点我 C++ is a powerful, highly flexible, and adaptable programming language that allows software ...