2013-12-10 46 views
2

每次我尝试推我的项目到Heroku通过使用git push heroku master我得到以下回应。我有一台MacBook Air OSX-10.8。上传到heroku导致错误

-----> Ruby app detected 
    -----> Compiling Ruby/Rails 
    -----> Using Ruby version: ruby-2.0.0 
    -----> Installing dependencies using Bundler version 1.3.2 
      New app detected loading default bundler cache 
      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/.. 
      Fetching git://github.com/thomas-mcdonald/bootstrap-sass.git 
      fatal: Could not parse object '9c6c07f74ff515cf38380b014cfede14a4f0eae4'. 
      Git error: command `git reset --hard 9c6c07f74ff515cf38380b014cfede14a4f0eae4` 
      in directory 
      /tmp/build_260d9aa7-1d8e-4738-b10f- fce9113dd86e/vendor/bundle/ruby/2.0.0/bundler/gems/bootstrap-sass-9c6c07f74ff5 
      has failed. 
      If this error persists you could try removing the cache directory 
      '/tmp/build_260d9aa7-1d8e-4738-b10f-fce9113dd86e/vendor/bundle/ruby/2.0.0/cache/bundler/git/bootstrap-sass-33efd1d8ffb6176fdb805029a30f02a6edfbae2e' 
      Bundler Output: Fetching gem metadata from https://rubygems.org/.......... 
      Fetching gem metadata from https://rubygems.org/.. 
      Fetching git://github.com/thomas-mcdonald/bootstrap-sass.git 
      fatal: Could not parse object '9c6c07f74ff515cf38380b014cfede14a4f0eae4'. 
      Git error: command `git reset --hard 9c6c07f74ff515cf38380b014cfede14a4f0eae4` 
      in directory 
      /tmp/build_260d9aa7-1d8e-4738-b10f-fce9113dd86e/vendor/bundle/ruby/2.0.0/bundler/gems/bootstrap-sass-9c6c07f74ff5 
     has failed. 
     If this error persists you could try removing the cache directory 
     '/tmp/build_260d9aa7-1d8e-4738-b10f-fce9113dd86e/vendor/bundle/ruby/2.0.0/cache/bundler/git/bootstrap-sass-33efd1d8ffb6176fdb805029a30f02a6edfbae2e' 
! 
!  Failed to install gems via Bundler. 
! 

!  Push rejected, failed to compile Ruby app 

To [email protected]:fierce-taiga-8706.git 
! [remote rejected] master -> master (pre-receive hook declined) 
error: failed to push some refs to '[email protected]:fierce-taiga-8706.git' 

这里是我的git的遥控器

heroku [email protected]:sheltered-crag-6550.git (fetch) 
heroku [email protected]:sheltered-crag-6550.git (push) 
origin [email protected]:TheM00se/Pinteresting.git (fetch) 
origin [email protected]:TheM00se/Pinteresting.git (push 

,这里是我的Gemfile

source 'https://rubygems.org' 



gem 'rails', '4.0.1' 
gem 'sass-rails', '~> 4.0.0' 
gem 'uglifier', '>= 1.3.0' 
gem 'coffee-rails', '~> 4.0.0' 
gem 'jquery-rails' 
gem 'turbolinks' 
gem 'jbuilder', '~> 1.2' 
gem 'bootstrap-sass', github: 'thomas-mcdonald/bootstrap-sass', branch: '3' 

group :doc do 
    gem 'sdoc', require: false 
end 

group :development, :test do 
    gem 'sqlite3' 
end 

group :production do 
    gem 'pg' 
    gem 'rails_12factor' 
end 

我一直在试图找出2小时解决,真的我不是甚至可以确定问题是什么。

回答

2

的问题是:

gem 'bootstrap-sass', github: 'thomas-mcdonald/bootstrap-sass', branch: '3' 

如果您检查下面的链接:

https://github.com/thomas-mcdonald/bootstrap-sass/branches

分支似乎被删除,也许它被合并到主分支的基础上,来自OP的反馈,任何随后使用它的人都应该将以下内容添加到他们的Gemfile中:

gem 'sass-rails', '>= 3.2' # sass-rails needs to be higher than 3.2 
gem 'bootstrap-sass', '~> 3.0.3.0' 
+0

我用第二行取代了行,并在 git://github.com/thomas-mcdonald/bootstrap-sass.git()找到了一条错误消息,说“无法找到宝石'boostrap-sass(> = 0)ruby'在主人)。 来源不包含任何版本的'boostrap-sass(> = 0)ruby'“ – TheM00s3

+0

我遵循托马斯麦克唐纳制定的约定,它的工作 – TheM00s3

+0

我更新了我的答案,以便后续需要的人 – bjhaid