升级 Ruby (1.9->2) &适用于 Windows 的 Rails(3.2->4) [英] Upgrading Ruby (1.9->2) & Rails(3.2->4) for Windows

查看:29
本文介绍了升级 Ruby (1.9->2) &适用于 Windows 的 Rails(3.2->4)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我还是 RoR 的新手,我遵循了教程并一直在开发一些应用程序.我已经安装了 http://railsinstaller.org/en对于我的 Windows 7 64 位操作系统.

I'm still new to RoR followed a tutorial and have been developing some apps. I've installed http://railsinstaller.org/en For my Windows 7 64-bit operating system.

我希望升级:

Ruby - 1.9.3p392 -> 2.0.0Rails - 3.2.13 -> 4

Ruby - 1.9.3p392 -> 2.0.0 Rails - 3.2.13 -> 4

Rails 安装程序没有这个可用.要升级 Ruby,我应该在 http://rubyinstaller.org/ 下载安装程序吗?我可以下载它,但是如何正确地将我的 ruby​​ 版本覆盖到 ugprade.与 Rails 4 相同.寻找任何指向正确方向的指针.

Rails installer doesn't have this available. To Upgrade Ruby, should I download the installer at http://rubyinstaller.org/? I could download it but how can I properly overwrite my ruby version to ugprade. Same with Rails 4. Looking for any pointers to get off in the right direction.

谢谢.

推荐答案

基本上有三个选项可以在 Windows 上获取最新版本的 Ruby.

There are basically three options to get the latest version of Ruby on Windows.

  1. http://rubyinstaller.org 下载 Ruby 2.0.0 并更改 Windows 环境变量中的 PATH.
  2. 使用 pik 来管理 Ruby 版本.
  3. 卸载 RailsInstaller 并从 Github
  1. Download Ruby 2.0.0 from http://rubyinstaller.org and change the PATH in your windows environment variables.
  2. Use pik to manage Ruby versions.
  3. Uninstall RailsInstaller and try the 3.0.0-alpha version from Github

需要注意的是,某些 gem,例如 sqlite3,可能需要使用 Ruby 2 进行手动编译.

Something to be aware of is that some gems, such as sqlite3, may require manual compilation with Ruby 2.

对于 Rails 4,最好的办法是在您的项目中使用 Bundler 并以这种方式安装它.RailsInstaller 应该是 Bundler-aware,不同的版本不应该相互冲突.

For Rails 4, the best bet would be to use Bundler in your project and install it that way. RailsInstaller should be Bundler-aware and different versions should not conflict with each other.

希望对您有所帮助,如果您还有其他问题,请查看 RailsInstaller Google Group 或 Freenode IRC 上的 #railsinstaller.

Hope that helps and if you have further questions, check out the RailsInstaller Google Group or #railsinstaller on Freenode IRC.

埃文

这篇关于升级 Ruby (1.9->2) &适用于 Windows 的 Rails(3.2->4)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆