1

一旦我安装了rails,如果我启动一个新应用程序,我就会收到这个错误:

nicolamac:app2 n$ rails new app
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
/Library/Ruby/Gems/1.8/gems/bundler-1.0.21/lib/bundler/spec_set.rb:88:in `materialize': Could not find multi_json-1.2.0 in any of the sources (Bundler::GemNotFound)
    from /Library/Ruby/Gems/1.8/gems/bundler-1.0.21/lib/bundler/spec_set.rb:82:in `map!'
    from /Library/Ruby/Gems/1.8/gems/bundler-1.0.21/lib/bundler/spec_set.rb:82:in `materialize'
    from /Library/Ruby/Gems/1.8/gems/bundler-1.0.21/lib/bundler/definition.rb:90:in `specs'
    from /Library/Ruby/Gems/1.8/gems/bundler-1.0.21/lib/bundler/definition.rb:135:in `specs_for'
    from /Library/Ruby/Gems/1.8/gems/bundler-1.0.21/lib/bundler/definition.rb:124:in `requested_specs'
    from /Library/Ruby/Gems/1.8/gems/bundler-1.0.21/lib/bundler/environment.rb:23:in `requested_specs'
    from /Library/Ruby/Gems/1.8/gems/bundler-1.0.21/lib/bundler/runtime.rb:11:in `setup'
    from /Library/Ruby/Gems/1.8/gems/bundler-1.0.21/lib/bundler.rb:110:in `setup'
    from /Users/n/Downloads/berk-platform-0e35856/test/dummy/config/boot.rb:7
    from /Users/n/Downloads/berk-platform-0e35856/test/dummy/script/rails:5:in `require'
    from /Users/n/Downloads/berk-platform-0e35856/test/dummy/script/rails:5
    from script/rails:6:in `load'
    from script/rails:6

任何的想法?

4

1 回答 1

1

看起来它试图在系统文件夹中初始化一个 git repo。查看rbenv,您的设置压力会更小。

于 2012-05-14T12:48:18.240 回答