有人能帮帮我吗?
我正在遵循https://github.com/plataformatec/devise的“入门”说明,当我运行rails generate devise:install
时,我收到以下错误(我的ruby是版本1.8.3和Rails 3.2.17):
C:/Ruby187/lib/ruby/gems/1.8/gems/bundler-1.6.2/lib/bundler/runtime.rb:76:in `re
quire': C:/Ruby187/lib/ruby/gems/1.8/gems/devise-3.2.4/lib/devise.rb:452: syntax
error, unexpected ':', expecting kEND (SyntaxError)
...ults mapping.name, strategies: mapping.strategies
^
from C:/Ruby187/lib/ruby/gems/1.8/gems/bundler-1.6.2/lib/bundler/runtime
.rb:76:in `require'
from C:/Ruby187/lib/ruby/gems/1.8/gems/bundler-1.6.2/lib/bundler/runtime
.rb:72:in `each'
from C:/Ruby187/lib/ruby/gems/1.8/gems/bundler-1.6.2/lib/bundler/runtime
.rb:72:in `require'
from C:/Ruby187/lib/ruby/gems/1.8/gems/bundler-1.6.2/lib/bundler/runtime
.rb:61:in `each'
from C:/Ruby187/lib/ruby/gems/1.8/gems/bundler-1.6.2/lib/bundler/runtime
.rb:61:in `require'
from C:/Ruby187/lib/ruby/gems/1.8/gems/bundler-1.6.2/lib/bundler.rb:132:
in `require'
from C:/Users/Adit/Documents/Rails/blog187/config/application.rb:7
from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.17/lib/rails/command
s.rb:24:in `require'
from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.17/lib/rails/command
s.rb:24
from script/rails:6:in `require'
from script/rails:6
答案 0 :(得分:1)
您尝试使用的设计版本(Devise 3)与Ruby 1.8.3不兼容
如果可以将Ruby更新为1.9.3或更新版本。