ruby2.0.0版本安装devkit遇到的问题

下载了ruby-2.0.0-p598-x64-mingw32压缩包,本地解压配了环境变量后,安装cucumber发生了错误:

Fetching: gherkin-2.12.2.gem (100%)
ERROR:  Error installing cucumber:
        The 'gherkin' native gem requires installed build tools.

Please update your PATH to include build tools or download the DevKit
from 'http://rubyinstaller.org/downloads' and follow the instructions
at 'http://github.com/oneclick/rubyinstaller/wiki/Development-Kit'

于是按照提示去development-kit网站去下载,对应的ruby2.0.0版本的devkit是 DevKit-mingw64-64-4.7.2-20130224-1432-sfx.exe这个包。解压后按照命令依次执行:

ruby dk.rb init
ruby dk.rb install
ruby dk.rb review

却又遇到这个错误提示:

Invalid configuration or no Rubies listed. Please fix 'config.yml'
and rerun 'ruby dk.rb install'

我手动去devkit目录下找到config.yml文件,在里面增加了" - D:/ruby2.0.0"解决了该问题,不过按照官网的说法,应该还有这样的解决方式, 点击这里查看。

判断是否安装成功可以试试这个命令:gem install json --platform=ruby

这个时候再回过头去安装cucumber,安装成功。

Temporarily enhancing PATH to include DevKit...
Building native extensions.  This could take a while...
Successfully installed gherkin-2.12.2
Fetching: multi_test-0.1.1.gem (100%)
Successfully installed multi_test-0.1.1
Fetching: cucumber-1.3.18.gem (100%)
Successfully installed cucumber-1.3.18
Parsing documentation for gherkin-2.12.2
Installing ri documentation for gherkin-2.12.2
Parsing documentation for multi_test-0.1.1
Installing ri documentation for multi_test-0.1.1
Parsing documentation for cucumber-1.3.18
Installing ri documentation for cucumber-1.3.18
3 gems installed

每个人的环境都可能存在不同的问题,记录在这里给大家作为参考。


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值