Solved

Git merge question

Posted on 2011-09-19
3
954 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
  • 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

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Have you ever been frustrated by having to click seven times in order to retrieve a small bit of information from the web, always the same seven clicks, scrolling down and down until you reach your target? When you know the benefits of the command l…
I've been asked to discuss some of the UX activities that I'm using with my team. Here I will share some details about how we approach UX projects.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

746 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

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now