现在我的bootstrap css版本是v2.3.2,带有以下gem
gem 'bootstrap-sass', '~> 2.3.2.1'
我尝试使用以下配置升级它
gem 'bootstrap-sass', git: 'https://github.com/thomas-mcdonald/bootstrap-sass.git', branch: '3'
但重新启动服务器后,版本保持不变
所以我尝试bundle exec rake convert
,也许它可以解决问题
但它一直在抛掷
Don't know how to build task 'convert'
那么有没有人知道如何在我的rails项目中实现bootstrap v3 ??
答案 0 :(得分:10)
我必须运行此命令
rake tmp:clear
为了从bootstrap v2文件中清除缓存
答案 1 :(得分:2)
根据rubygems.org上的说明,您必须运行此命令才能获得新的gem。我认为这是因为它正在使用候选版本。
$ gem install bootstrap-sass --pre
我不知道如何在Gemfile中执行此操作。
答案 2 :(得分:0)
bootstrap-sass github页面不太清楚。 您不需要来运行转换任务,除非您正在开发或开发gem本身。 您只需按照bootstrap-sass rails install guide
进行操作即可