2017-03-16 160 views
1

我寧願不寫這個。但痛苦是,我不知道什麼是衝突或什麼,我發現它在gemfile.lock和DELETED IT!我讀過一個人說不這樣做,所以我不知道如何解決我的問題。這是我的gemfile和gemfile.lock。刪除了Gemfile.lock中的合併衝突

-------->的Gemfile < ----------

source 'https://rubygems.org' 



ruby '2.2.6' 

git_source(:github) do |repo_name| 
    repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/") 
    "https://github.com/#{repo_name}.git" 
end 


gem 'rails', '~> 5.0.1' 
gem 'puma', '~> 3.0' 
gem 'sass-rails', '~> 5.0' 
gem 'uglifier', '>= 1.3.0' 
gem 'coffee-rails', '~> 4.2' 
gem 'jquery-rails' 


gem 'jquery-ui-rails', '~> 5.0.5' 
gem 'turbolinks', '~> 5' 
gem 'jbuilder', '~> 2.5' 
gem 'bootstrap', '~> 4.0.0.alpha6' 
gem 'devise' 
gem 'activeadmin', '~> 1.0.0.pre5' 
gem 'inherited_resources', github: 'activeadmin/inherited_resources' 
group :development, :test do 
    gem 'byebug', platform: :mri 
    gem 'sqlite3' 
end 

group :development do 
    gem 'web-console', '>= 3.3.0' 
end 

group :production do 
    gem 'pg' 
end 

gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby] 

--------->的Gemfile到此爲止< --- -----

 GIT 
     remote: https://github.com/activeadmin/inherited_resources.git 
    revision: eea3aa21f3867dc182e4db24d1c765bdbcb3df34 
    specs: 
    inherited_resources (1.7.0) 
     actionpack (>= 3.2, < 5.1) 
     has_scope (~> 0.6) 
     railties (>= 3.2, < 5.1) 
     responders 

GEM 
    remote: https://rubygems.org/ 
    specs: 
    actioncable (5.0.2) 
     actionpack (= 5.0.2) 
     nio4r (>= 1.2, < 3.0) 
     websocket-driver (~> 0.6.1) 
    actionmailer (5.0.2) 
     actionpack (= 5.0.2) 
     actionview (= 5.0.2) 
     activejob (= 5.0.2) 
     mail (~> 2.5, >= 2.5.4) 
     rails-dom-testing (~> 2.0) 
    actionpack (5.0.2) 
     actionview (= 5.0.2) 
     activesupport (= 5.0.2) 
     rack (~> 2.0) 
     rack-test (~> 0.6.3) 
     rails-dom-testing (~> 2.0) 
     rails-html-sanitizer (~> 1.0, >= 1.0.2) 
    actionview (5.0.2) 
     activesupport (= 5.0.2) 
     builder (~> 3.1) 
     erubis (~> 2.7.0) 
     rails-dom-testing (~> 2.0) 
     rails-html-sanitizer (~> 1.0, >= 1.0.3) 
    activeadmin (1.0.0.pre5) 
     arbre (~> 1.0, >= 1.0.2) 
     bourbon 
     coffee-rails 
     formtastic (~> 3.1) 
     formtastic_i18n 
     inherited_resources (~> 1.6) 
     jquery-rails 

--------> Gemfile.lock的到此爲止< ------------

+0

你究竟想要什麼? –

回答

0

您可以刪除G emfile.lock並運行以下命令即

bundle install 

它會再次創建Gemfile.lock並添加依賴項gem。

+0

非常感謝。找到另一種方式來運行'git reset --hard' –

+0

嘗試使用git checkout Gemfile.lock – puneet18

+0

git checkout Gemfile Gemfile.lock – puneet18