简体   繁体   English

不同版本的红宝石会出现问题吗?

[英]Can be problems with different version of ruby on rails?

Now on my localhost I'm starting developing first simple web service using ruby 1.9.2 and rails 3.2.1 versions . 现在在我的本地主机上,我开始使用ruby 1.9.2和rails 3.2.1版本开发第一个简单的Web服务。 But my hoster support only 2.3.14 version of ruby (becouse he is using Cpanel). 但是我的托管服务商仅支持2.3.14版本的ruby(因为他使用的是Cpanel)。 Will a have problem with this? 会有问题吗? how to prevent them? 如何预防? Moreover, what difference is between 3.2.1 and 2.3.14, I meen gems etc? 此外,3.2.1和2.3.14之间有什么区别? O it is better to start now developing using 2.3.14? O最好现在开始使用2.3.14开发吗? what gems would not work in 2.3.14? 2.3.14中哪些宝石不起作用? will haml, sass, captcha and other gems work in old version? haml,sass,captcha和其他宝石将在旧版本中工作吗?

Given you must use this host, I would suggest setting up your development environment to match. 鉴于您必须使用此主机,我建议您设置适合您的开发环境。 A nice way to manage having multiple versions of ruby and try different gems is to use rvm . 管理Ruby的多个版本并尝试不同的宝石的一种好方法是使用rvm This will allow you to manage multiple combinations of ruby (1.8.7, 1.9.2, ect) and multiple versions of rails and other associated gems. 这将允许您管理红宝石(1.8.7、1.9.2等)的多种组合以及导轨和其他关联宝石的多种版本。

As for the specific gems, both haml and sass will work with rails 2.3. 至于特定的宝石,haml和sass都可以在rails 2.3上使用。
I am not sure what captcha gem you wish to use but from the popular recaptcha gem readme: 我不确定您要使用哪种验证码宝石,但是从流行的Recaptcha gem自述文件中可以得出:

"Rails apps below 3.0 are no longer supported, but you can install an older release and view it's README." “不再支持低于3.0的Rails应用程序,但是您可以安装旧版本并查看其自述文件。”

All in all you can make this setup work and you should not disrepair. 总而言之,您可以使此安装程序正常运行,并且您不应失修。 There is a TON of example code out there on how to write and manage rails 2.3. 关于如何编写和管理rails 2.3,有一堆示例代码。 Good luck /Salernost 祝你好运/ Salernost

Maximum supported versions at this time are : 目前支持的最高版本为:

Ruby 1.8.7
RubyGems 1.8.25
Rails 2.3.18

Anything newer than that is a near guaranteed breakage and cPanel & WHM will be incapable of utilizing it in any way, shape, or form. 较新的东西几乎可以保证破损,cPanel&WHM将无法以任何方式,形状或形式使用它。

If you want to use any versions newer than this, then you will be unable to use the cPanel & WHM interfaces or management tools for it -- they simply will not work . 如果要使用比此版本更高的任何版本,则将无法使用cPanel&WHM接口或管理工具 - 它们根本无法使用 You will then have to manually manage your RoR install by yourself through command line exclusively. 然后,您将必须专门通过命令行手动手动管理RoR安装。 None of it would fall under the scope of cPanel support. 所有这些都不属于cPanel支持的范围。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM