本地安装rails

由于rails对各个gem包有先后的以来关系,如下:

gem install activesupport-1.3.1.gem
gem install activerecord-1.14.4.gem
gem install actionpack-1.12.5.gem
gem install actionmailer-1.2.5.gem
gem install actionwebservice-1.1.6.gem
gem install rake-0.7.1.gem
gem install rails-1.1.6.gem
运行 rails -v 显示版本号,表示安装成功。


在WINDOWS下配置RadRails
[ 2007-01-11 11:44:36 | 作者: Admin ]
: | |
From RadRails go to Window > Preferences > Ruby > Installed Interpreters. Click the "Add" button. For "Interpreter Name" just put "Ruby" (name doesn't really matter). For the path put the path to your "ruby.exe" file. On my machine this path is "c:\ruby\bin\ruby.exe". Your path may be different depending on where you installed ruby.

Now on to rails and rake.

For rails goto Window > Preferences > Rails > Configuration. For the "rails path" you need to specify the complete path to the "rails" program (the "rails.cmd" file will not work). There should be a file in your ruby\bin directory called "rails" (no file extension) and there will also be a file called "rails.cmd". You want the "rails" file. My complete path looks like this "C:\ruby\bin\rails" (you will need to include the path AND the "rails" file not just c:\ruby\bin). The most common mistake I've seen is people setting the path to the rails.cmd file. This won't work.

For rake goto Window > Preferences > Rails > Configuration. For the "rake path" you need to specify the complete path to the "rake" program (the "rake.bat" or "rake.cmd" files will not work). There should be a file in your ruby\bin directory called "rake" (no file extension) and there will also be a file called "rake.cmd" and "rake.bat". You want the "rake" file. My complete path looks like this "C:\ruby\bin\rake" (you will need to include the path AND the "rake" file not just c:\ruby\bin). The most common mistake I've seen is people setting the path to the rake.bat or rake.cmd files. This won't work. If you don't have a file in your ruby/bin directory called "rake" try to do a "gem update rake" or "gem install rake" from the command line and that should fix it.

Want to make RI and RDOC work?

Goto Window > Preferences > Ruby > Ri/Rdoc. For RI put in something like "C:\ruby\bin\ri" (again, not the .bat file, just the plain Jane "ri" file) and for Rdoc put in something like "C:\ruby\bin\rdoc".

For those of you using mongrel and wanting to use mongrel servers within RadRails, you will need to specify the path to "mongrel_rails". Goto Window > Preferences > Rails > Configuration. My "mongrel path" looks like this "C:\ruby\bin\mongrel_rails". As with rake and rails, you do NOT want the "mongrel_rails.cmd" file.

附:
RadRails地址: http://www.radrails.org
RadRails运行需要Java Runtime Environment,可以到 http://www.java.com 下载。
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值