3

我正在尝试使用此处的模板创建项目

但是当我试图执行时

rails new app -m https://raw.github.com/rails3-application-templates/blob/master/rails3-bootstrap-devise-cancan-template.rb -T

它说

/Users/alex/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:247:in `to_specs': Could not find railties (>= 0) amongst [bigdecimal-1.1.0, io-console-0.3, json-1.5.4, minitest-2.5.1, rake-0.9.2.2, rdoc-3.9.4] (Gem::LoadError)
    from /Users/alex/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:256:in `to_spec'
    from /Users/alex/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems.rb:1231:in `gem'
    from /Users/alex/.rvm/gems/ruby-1.9.3-p194/bin/rails:18:in `<main>'
    from /Users/alex/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in `eval'
    from /Users/alex/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in `<main>'

我用谷歌搜索了这个问题,在stackoverflow上找到了几个答案,但没有任何帮助。我尝试重新安装 rails\ruby、rvm、设置 ruby​​ 的默认版本等等。知道要尝试什么吗?

4

1 回答 1

3

模板已弃用,似乎不起作用。页面上是模板的弃用消息,请参见此处。请尝试使用Rails Composer

于 2012-08-28T21:12:29.490 回答