代码之家  ›  专栏  ›  技术社区  ›  Blankman

RVM目前是1.9.2,想在1.8.7上运行我的应用程序,我该怎么办?

  •  0
  • Blankman  · 技术社区  · 14 年前

    我是RVM的新手。

    所以我有一个RVM设置,其中包含ruby 1.9.2和rails 3。

    我想知道用Rails3测试1.8.7中的应用程序,我应该怎么做?

    我必须再次运行bundle安装吗?

    1 回复  |  直到 14 年前
        1
  •  3
  •   Daniel Mendel    14 年前

    是的,假设您已经安装了1.8.7和RVM: rvm install 1.8.7 ,并加载了rails 3 gem(记住,不要将sudo与rvm一起使用)。那就是:

    $> rvm 1.8.7
    $> cd /path/to/myApp
    $> bundle install
    $> rails server
    

    $> rvm gemset create rails3dev
    $> rvm 1.8.7@rails3dev
    $> cd /path/to/myApp
    $> bundle install
    $> rails server
    

    当然,这里面还有很多 the official RVM documentation