Solved

Git merge question

Posted on 2011-09-19
3
982 Views
Last Modified: 2012-05-12
I was trying to merge a branch, and got this error:

lv@machine:~/bp (integration)$ git merge aarp-perks
warning: Failed to merge submodule app/plugins/surveys (commits not present)
Auto-merging app/plugins/surveys
CONFLICT (submodule): Merge conflict in app/plugins/surveys
Automatic merge failed; fix conflicts and then commit the result.

so I did a gitstatus:


lv@machine:~/bp (integration)$ git status
# On branch integration
# Changes to be committed:
#
#      modified:   app/plugins/bp_events
#
# Unmerged paths:
#   (use "git add/rm <file>..." as appropriate to mark resolution)
#
#      both modified:      app/plugins/surveys
#
# Changes not staged for commit:
#   (use "git add <file>..." to update what will be committed)
#   (use "git checkout -- <file>..." to discard changes in working directory)
#   (commit or discard the untracked or modified content in submodules)
#
#      modified:   app/plugins/bp_events (untracked content)
#


Anyone know how I can resolve this so that I can merge the branch I am working on? I am new to this.
0
Comment
Question by:lvollmer
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 12

Accepted Solution

by:
JESii earned 500 total points
ID: 36564123
Try using:
   git mergetool
this opens your default diff program (or prompts you to select one if you haven't already) and then helps you figure out how to resolve the merge conflict (on app/plugins/surveys). Here's a link about that: http://gitguru.com/2009/02/22/integrating-git-with-a-visual-merge-tool/

Also, here's a terrific (free) book about git by Scott Chacon - highly recommended! Here's the section on branching and merging: http://progit.org/book/ch3-2.html
0
 

Author Comment

by:lvollmer
ID: 36567073
is there anyway to just overwrite the files on my machine with the latest copy of the repository?
0
 

Author Closing Comment

by:lvollmer
ID: 36567173
actually, that is easier then i thought it would be. thanks for the link.
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Learn by example how to specify CSS selectors for Selenium WebDriver test automation software.
Any business that wants to seriously grow needs to keep the needs and desires of an international audience of their websites in mind. Making a website friendly to international users isn’t prohibitively expensive and can provide an incredible return…
This video teaches users how to migrate an existing Wordpress website to a new domain.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question