【问题标题】:switch ruby for a single command via rvm通过 rvm 为单个命令切换 ruby
【发布时间】:2011-01-29 19:03:12
【问题描述】:

我想使用例如系统 capistrano/ruco/xxx 而不是将它们添加到我创建的每个 ruby​​/gemset 中。

所以通常rvm ruby_with_all_gems ... do_something ... rvm back_to_other

有什么好的解决方案可以用来做吗? alias capree="rvm with ree cap"?

【问题讨论】:

    标签: ruby bash rvm


    【解决方案1】:

    rvm exec ree cap 它已经将 i 构建到 rvm :>

    【讨论】:

      【解决方案2】:

      我建议使用函数:

      伪代码:

      capree () {
          save rvm state
          do rvm op with args "$@"
          restore rvm state
      }
      

      【讨论】:

        猜你喜欢
        • 2013-07-01
        • 1970-01-01
        • 1970-01-01
        • 2011-10-02
        • 1970-01-01
        • 1970-01-01
        • 2023-02-07
        • 1970-01-01
        • 2013-03-07
        相关资源
        最近更新 更多