这个是由于被墙了的原因,提供一个不用翻墙解决的方法

淘宝做了一个gem镜像,地址是http://ruby.taobao.org/ 

为什么有这个?

由于国内网络原因(你懂的),导致 rubygems.org 存放在 Amazon S3 上面的资源文件间歇性连接失败。所以你会与遇到 gem install rackbundle install的时候半天没有响应,具体可以用 gem install rails -V 来查看执行过程。

这是一个完整 rubygems.org 镜像,你可以用此代替官方版本,同步频率目前为15分钟一次以保证尽量与官方服务同步。

如何使用?
$ gem sources --remove https://rubygems.org/
$ gem sources -a https://ruby.taobao.org/
$ gem sources -l
*** CURRENT SOURCES *** https://ruby.taobao.org
# 请确保只有 ruby.taobao.org
$ gem install rails
如果你使用 Gemfile 和 Bundle (例如:Rails 项目)

你可以用bundle的gem源代码镜像命令

$ bundle config mirror.https://rubygems.org https://ruby.taobao.org

这样你不用改你的 Gemfile 的 source。

source 'https://rubygems.org/'
gem 'rails', '4.1.0'
...
$bundle install
Ruby 源代码镜像

Ruby 源代码下载镜像

本镜像来源于 cache.ruby-lang.org 用于改善国内 Ruby 安装的速度。

修改 RVM ,改用本站作为下载源, 提高安装速度。

FOR MAC
$ sed -i .bak 's!cache.ruby-lang.org/pub/ruby!ruby.taobao.org/mirrors/ruby!' $rvm_path/config/db
FOR LINUX
$ sed -i 's!cache.ruby-lang.org/pub/ruby!ruby.taobao.org/mirrors/ruby!' $rvm_path/config/db

.

bundle install rake-10.4.2的更多相关文章

  1. rake aborted! You have already activated rake 10.1.0, but your Gemfile requires rake 10.0.3. Using bundle exec may solve this.

    问题: wyy@wyy:~/moumentei-master$ rake db:createrake aborted!You have already activated rake 10.1.0, b ...

  2. 关于bundle install 的一点补充

    在第一次运行bundle install之后,生成了Gemfile.lock文件,里面记录gem的具体版本号,按照官方文档说明,以后运行bundle install就不会再依据Gemfile,而是根据 ...

  3. rake :You have already activated rake 10.1.0

    rake aborted! You have already activated rake 10.1.0, but your Gemfile requires rake 10.0.3. Using b ...

  4. [转载]提高rails new时bundle install运行速度

    最近在新建rails项目时,rails new老是卡在bundle install那里,少则五分钟,多则几十分.这是因为rails new时自动会运行bundle install,而bundle in ...

  5. 【RoR win32】提高rails new时bundle install运行速度

    在新建rails项目时,rails new老是卡在bundle install那里,少则五分钟,多则几十分.这是因为rails new时自动会运行bundle install,而bundle inst ...

  6. bundle install 出现 'gem install mysql2 -v '0.3.15' succeeds before bunding '

    bundle install 出现  'gem install mysql2 -v '0.3.15' succeeds before bunding ' 解决:sudo apt-get install ...

  7. install MariaDB 10.2 on Ubuntu 18

    Here are the commands to run to install MariaDB 10.2 from the MariaDB repository on your Ubuntu syst ...

  8. bundle install 安装的 gem 提示 cannot load such file

    /usr/local/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:54:in `require': cannot load ...

  9. bundle install 老是中断,可以在gemfile里面把source换成taobao源,可以自动安装

    bundle install 老是中断,可以在gemfile里面把source换成taobao源,可以自动安装

随机推荐

  1. git环境搭建

    Linux kernel  的官方 GIT地址是: http://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git 可以从这个地 ...

  2. Eclipse 下如何删除一个项目的 SVN 信息

    选中项目,右键 - Team - 断开连接 出现如下对话框,根据需要,选择 “删除”或者“不删除”,点击 Yes 即可

  3. dataguru试听课程

    http://www.dataguru.cn/article-5447-1.html#userconsent#

  4. python下载图片

    import re import  urllib.request   def getHtml(url): page = urllib.request.urlopen(url) html = page. ...

  5. leetcode:Merge Two Sorted Lists(有序链表的归并)

    Merge two sorted linked lists and return it as a new list. The new list should be made by splicing t ...

  6. 《OD学算法》常用算法集合

    1. 排序 (1)冒泡 (2)选择 (3)插入 (4)归并 2. 位运算 Bitmask provide an efficient way to manipulate a small set of B ...

  7. Hadoop集群(第3期)_VSFTP安装配置

    1.VSFTP简介 VSFTP是一个基于GPL发布的类Unix系统上使用的FTP服务器软件,它的全称是Very Secure FTP 从此名称可以看出来,编制者的初衷是代码的安全. 安全性是编写VSF ...

  8. maven命令大全

    1. mvn help:describe 你是否因为记不清某个插件有哪些goal而痛苦过,你是否因为想不起某个goal有哪些参数而苦恼,那就试试这个命令吧,它会告诉你一切的. 参数: 1. -Dplu ...

  9. [ionic开源项目教程] - 第3讲 左右滑动菜单的实现(使用Tabs和SlideBox)

    使用Tabs和SlideBox实现左右滑动菜单 1.将tab1.html的代码改为如下: <ion-view view-title="健康"> <ion-cont ...

  10. Qt环境搭建(Visual Studio)

    简述 经常有人问我编写Qt程序时使用什么IDE,其实这个真的很难回答(各有所长),只能说看个人爱好了,因为我两个都用,而且两个都很喜欢(比较多情吧O(∩_∩)O~)! 下面将进行Qt Creator与 ...