Ruby Windows 7 下 Ruby 2.0.0-p353 挺好用的……

ericguo · 2013年05月18日 · 最后由 yangff 回复于 2013年10月07日 · 11929 次阅读

Rails 4.0.2, Rails 3.2.16, Octopress, oracle 数据库驱动,反正我想用的 gems 都可以在 Windows 下正常工作,而且 rails s 速度明显快了不少

分享安装过程的几个坑:

Need manually install the sqlite3.

1. run C:\DevKit\devkitvars.bat 2. mkdir c:\temp 3. download http://packages.openknapsack.org/sqlite/sqlite-3.7.15.2-x86-windows.tar.lzma to c:\temp 4. c:\Temp>bsdtar --lzma -xf sqlite-3.7.15.2-x86-windows.tar.lzma 5. c:\Temp>gem install sqlite3 --platform=ruby -- --with-opt-dir=C:/Temp

2. Using below .gemrc and reinstall the gems like yajl-ruby, win32console or bcrypt-ruby if you found the x86-mingw32 version can not work out of box.

---
:backtrace: false
:benchmark: false
:bulk_threshold: 1000
:sources:
- http://ruby.taobao.org
:update_sources: true
:verbose: true
gem: --no-document --platform=ruby

You may want to comment out the "DL is deprecated, please use Fiddle" warning

code at C:\Ruby200\lib\ruby\2.0.0\dl.rb since it's annoy and you are not the irb/pry or some other gems code owner...

最后,今天给同事装,发现对初学者来说还是有点坑,所以这里提供一个 115 的直接安装镜像包,安装好以后直接把 C:\Ruby200 目录替换为这个压缩包里面的内容即可,可能更简单一点。

@ericguo 我的 64 位 win7 怎么安装不了 thin 呀,不知道你遇到没有?

#3 楼 @zlfera 我用的 32 位,并且 thin 安装正常。。。

@ericguo你用的 devkit 是什么版的?

@zlfera 64 位的选 mingw64-64 好了

@luikore @ericguo win7 下不能安装 thin 呀

#8 楼 @zlfera 不清楚,反正 32 位 windows 7, ruby 2.0.0-p195+thin 1.5.1 是可以安装和使用的。

windows 就用 vagrant 虚拟吧,共享文件夹、ssh 登录操作,非常方便

速度超快,就是 nokogiri 没法用

@ericguo在 win7 上装了 ruby2.0 当我打开 IRB 时上面为什么显示 DL is deprecated, please use Fiddle?不过其他一切正常。那如何使用 fiddle?

windows...各种的不爽,对于 ruby、rails 什么的

其实在乎的不是环境,只要能用就好。

赶紧回家装上试试

我用 64 位 win8 安装 64 位 Ruby 2.0.0-p195 用着也不错

@ericguo 你好问一下你在 windows7 下安装 ruby2.0 那个 sqlite3 下什么版本我在官网下的怎么没用?你的在哪里下的?谢谢

18 楼 已删除

win 下面一些好的 gem 都没有办法用

直接安装包有更新,现在这个 200 兆的压缩包已经包括了 rails 4.0.2, rails 3.2.16 以及 devkit http://115.com/lb/5lbcqj8lbp7g#Ruby200.rar 首先安装 32 位 Rubyinstaller 2.0.0-p353,然后把这个压缩包直接解压缩到 C:\根目录

mysql 能编译么……

需要 登录 后方可回复, 如果你还没有账号请 注册新账号