【问题标题】:I can't push my Rails project to heroku, can't find bootstrap-sass我无法将我的 Rails 项目推送到 heroku,找不到 bootstrap-sass
【发布时间】:2013-05-01 21:50:21
【问题描述】:

当我尝试将我的项目推送到 Heroku 时,我收到此错误:

-----> Deleting 3 files matching .slugignore patterns.
-----> Ruby/Rails app detected
-----> Using Ruby version: ruby-1.9.3
-----> Installing dependencies using Bundler version 1.3.2
       Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin --deployment
       Fetching gem metadata from https://rubygems.org/.......
       Fetching gem metadata from https://rubygems.org/..
       Could not find bootstrap-sass-2.3.1.1 in any of the sources
 !
 !     Failed to install gems via Bundler.
 !
 !     Heroku push rejected, failed to compile Ruby/rails app

To git@heroku.com:kerbal-space-station.git
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'git@heroku.com:kerbal-space-station.git'

但是我的 Gemfile 确实有这个功能,并且 bundle install 在本地可以正常工作。

【问题讨论】:

    标签: ruby-on-rails ruby heroku gem bundler


    【解决方案1】:

    bootstrap-sass 2.3.1.1 被拉出:https://rubygems.org/gems/bootstrap-sass/versions

    你应该运行:

    bundle update bootstrap-sass
    

    然后提交新的 Gemfile.lock 并推送到 heroku

    【讨论】:

    • 耶稣,我想知道为什么 bundle update / bundle install 没有捕捉到这个。
    【解决方案2】:

    bootstrap-sass 的最新版本是 2.3.1.0,您正在寻找 2.3.1.1,但它不存在。

    检查您的 gemfile 并添加:

    gem 'bootstrap-sass', '2.3.1.0'
    

    【讨论】:

      【解决方案3】:

      你不需要放你只能放的版本号

      gem 'bootstrap-sass'
      

      然后做

      bundle update
      

      【讨论】:

      • 版本号可防止重大补丁更改,您应始终使用乐观的版本要求。
      猜你喜欢
      • 2014-06-26
      • 2018-12-19
      • 2012-12-19
      • 2013-01-09
      • 1970-01-01
      • 2013-09-11
      • 1970-01-01
      • 2021-12-22
      • 2014-11-01
      相关资源
      最近更新 更多