【问题标题】:Cannot install ruby 1.9.3 using RVM. Seems to be some type of git error无法使用 RVM 安装 ruby​​ 1.9.3。似乎是某种类型的 git 错误
【发布时间】:2012-11-09 16:36:21
【问题描述】:

当我执行rvm install ruby-1.9.3-head 时,我得到这个错误:

➜  ~  rvm install ruby-1.9.3-head
Installing Ruby from source to: /Users/max/.rvm/rubies/ruby-1.9.3-head, this may take a while depending on your cpu(s)...
fatal: Not a git repository (or any of the parent directories): .git
fatal: Not a git repository (or any of the parent directories): .git
fatal: Not a git repository (or any of the parent directories): .git
fatal: Not a git repository (or any of the parent directories): .git
fatal: Not a git repository (or any of the parent directories): .git
Branch origin/ruby_1_9_3 not found.
There has been an error while checking out branch ruby_1_9_3.  
Halting the installation.
There has been an error fetching the ruby interpreter. Halting the installation.

ruby-1.9.3-head is not installed.
To install do: 'rvm install ruby-1.9.3-head'

有谁知道如何解决这个问题?

【问题讨论】:

  • 我最近通过 rvm 安装了 ruby​​ 1.9.3,但我只是使用了rvm install ruby-1.9.3。 RVM 将使用该命令安装ruby-1.9.3p286
  • 得分较高的答案应该被标记为正确,因为它是一个更直接的解决方案。 “重新安装操作系统”也可能有效,但这不是解决问题的正确方法。

标签: ruby macos rvm


【解决方案1】:

我遇到了类似的问题,似乎某些存储库数据已过期/损坏。

➜ rvm cleanup repos 解决了这个问题并解决了我的问题。

【讨论】:

    【解决方案2】:

    先尝试rvm get stablervm get head。您的 RVM 版本可能已过时。

    【讨论】:

    • 谢谢,这似乎解决了问题。
    猜你喜欢
    • 1970-01-01
    • 2012-07-23
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多