所以我试图用omniauth添加facebook身份验证,并注意到我无法使用
生成控制器rails generate controller Sessions new create destroy
因为我收到以下错误消息:
Could not find bootstrap-sass-3.2.0.2 in any of the sources
Run `bundle install` to install missing gems.
我尝试卸载并重新安装不同版本的gem,破坏捆绑更新等,但没有成功。 我正在运行rails 4.1.5并使用ruby 2.1.2。 这是我的gemfile中的当前行:
gem 'bootstrap-sass', '~> 3.2.0
我在应用程序的目录中,并尝试使用bundle exec运行命令,但没有任何更改。
答案 0 :(得分:1)
没有足够的信誉使这个评论...但你的宝石线看起来像是缺少单引号。应该是:
gem 'bootstrap-sass', '~> 3.2.0'
答案 1 :(得分:1)
您可能需要杀死所有弹簧:
myapp swards$ ps aux | grep spring
swards 46617 0.1 0.3 2478996 22112 ?? Ss 1:27AM 0:00.57 spring app | my-app | started 2 mins ago | development mode
swards 46632 0.0 0.0 2442000 648 s002 S+ 1:30AM 0:00.00 grep spring
swards 45116 0.0 0.2 2504588 15332 s002 S 10:55PM 0:00.30 spring server | my-app | started 2 hours ago
myapp swards$ kill 46617
myapp swards$ kill 45116
答案 2 :(得分:0)
使用bundle exec运行命令:
bundle exec rails generate controller Sessions new create destroy
这将确保所有捆绑的宝石都可用于Rails。