清理Ruby版本和宝石?

时间:2013-11-29 02:54:49

标签: ruby-on-rails ruby gem install bundle

我真的需要你的专业知识。我是Ruby和宝石的新手,搞砸了我的电脑设置。我得到了大致的工作,但今天做了更多的宝石安装后,我决定是时候一劳永逸地修复我的Ruby和宝石了。

我使用RVM。

下:

/Users/Jonathan/.rvm/gems 

我明白了:

cache
ruby-1.9.2-p320
ruby-1.9.3-p448
ruby-1.9.3-p448@global
ruby-2.0.0-p247
ruby-2.0.0-p247@global

但是当我rvm list时,它只能看到一个Ruby:

rvm rubies

=* ruby-1.9.3-p448 [ x86_64 ]

我怀疑当我尝试将它一起黑客攻击时,我搞砸了我的Ruby安装,因为: 1. RVM显然与上面看到的Ruby的许多版本不一致。 2.刚刚执行bundle install时出现“拒绝许可”错误:

    Installing coffee-script-source (1.6.3)
    Errno::EACCES: Permission denied - /Users/Jonathan/.rvm/gems/ruby-1.9.3-p448/build_info/coffee-script-source-1.6.3.info
    An error occurred while installing coffee-script-source (1.6.3), and Bundler cannot continue.
    Make sure that `gem install coffee-script-source -v '1.6.3'` succeeds before bundling.

其中,从其他Stack Overflow帖子中,似乎暗示我安装了Ruby和宝石错误,并搞砸了我不应该做的事情。

这是我的$PATH输出供参考:

/Users/Jonathan/.rvm/gems/ruby-1.9.3-p448/bin:/Users/Jonathan/.rvm/gems/ruby-1.9.3-p448@global/bin:/Users/Jonathan/.rvm/rubies/ruby-1.9.3-p448/bin:/Users/Jonathan/.rvm/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/local/git/bin:/Users/Jonathan/Development/adt-bundle-mac-x86_64-20130729/sdk/platform-tools

我假设当我使用gem install时,它将它安装到〜/ .rvm / gems / version-of-ruby-rvm-is-Currently-using / 但我不确定,也不确定每个目录是否也都是宝石集。

我很丢失。

非常感谢你的帮助!

更新正在运行的rvm info:

$ rvm info

ruby-1.9.3-p448:

  system:
    uname:       "Darwin unknown7cd1c3db60f7 12.5.0 Darwin Kernel Version 12.5.0: Sun Sep 29 13:33:47 PDT 2013; root:xnu-2050.48.12~1/RELEASE_X86_64 x86_64"
    system:      "osx/10.8/x86_64"
    bash:        "/bin/bash => GNU bash, version 3.2.48(1)-release (x86_64-apple-darwin12)"
    zsh:         "/bin/zsh => zsh 4.3.11 (i386-apple-darwin12.0)"

  rvm:
    version:      "rvm 1.22.12 (stable) by Wayne E. Seguin <wayneeseguin@gmail.com>, Michal Papis <mpapis@gmail.com> [https://rvm.io/]"
    updated:      "2 months 2 days 14 hours 12 minutes 30 seconds ago"
    path:         "/Users/Jonathan/.rvm"

  ruby:
    interpreter:  "ruby"
    version:      "1.9.3p448"
    date:         "2013-06-27"
    platform:     "x86_64-darwin12.5.0"
    patchlevel:   "2013-06-27 revision 41675"
    full_version: "ruby 1.9.3p448 (2013-06-27 revision 41675) [x86_64-darwin12.5.0]"

  homes:
    gem:          "/Users/Jonathan/.rvm/gems/ruby-1.9.3-p448"
    ruby:         "/Users/Jonathan/.rvm/rubies/ruby-1.9.3-p448"

  binaries:
    ruby:         "/Users/Jonathan/.rvm/rubies/ruby-1.9.3-p448/bin/ruby"
    irb:          "/Users/Jonathan/.rvm/rubies/ruby-1.9.3-p448/bin/irb"
    gem:          "/Users/Jonathan/.rvm/rubies/ruby-1.9.3-p448/bin/gem"
    rake:         "/Users/Jonathan/.rvm/gems/ruby-1.9.3-p448/bin/rake"

  environment:
    PATH:         "/Users/Jonathan/.rvm/gems/ruby-1.9.3-p448/bin:/Users/Jonathan/.rvm/gems/ruby-1.9.3-p448@global/bin:/Users/Jonathan/.rvm/rubies/ruby-1.9.3-p448/bin:/Users/Jonathan/.rvm/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/local/git/bin:/Users/Jonathan/Development/adt-bundle-mac-x86_64-20130729/sdk/platform-tools"
    GEM_HOME:     "/Users/Jonathan/.rvm/gems/ruby-1.9.3-p448"
    GEM_PATH:     "/Users/Jonathan/.rvm/gems/ruby-1.9.3-p448:/Users/Jonathan/.rvm/gems/ruby-1.9.3-p448@global"
    MY_RUBY_HOME: "/Users/Jonathan/.rvm/rubies/ruby-1.9.3-p448"
    IRBRC:        "/Users/Jonathan/.rvm/rubies/ruby-1.9.3-p448/.irbrc"
    RUBYOPT:      ""
    gemset:       ""

0 个答案:

没有答案