git merge: conflicts in files that haven't been touched
I'll try to illustrate my problem by the following example:
I have linux kernel git repository containing 2.6.31-6 version with some modifications. I'd like to merge it with, say, 2.6.32. But during git pull <2.6.32 repository path> I see a lot of conflicts that have to be resolved manually in files I haven't ever touched.
What's wrong with that? I mean, git has full history of commits and it has an information about files that were modified after "parent commit" and files that were not. Why can't it apply the very last modifications on the files that were not touched?
UPDATE1: @DanAloni and @KevinBallard have explained why there appear conflicts while merging -rc with newer stable release.
But is there a way to reduce number of manual conflicts particularly in situation when -rc is merged with release?
UPDATE2: Thanks to @DanAloni for explanation
I'm trying to understand ... What's the difference between git merge and git rebase?
I did a git pull from my upstream on a clean working directory and it presents me with merge conflicts. I spent about an hour manually resetting them thinking I had screwed something up and it happene
How can I tell sbt-assembly to keep its existing merge / deduplicate rules, except, when two .class files conflice, rename (and issue a warning so I know about it)? Would this be identical to the shad
I have my source code in a mercurial repo, whereas the master branch has been moved from mercurial to a git repo. The current git master branch head and my mercurial version has conflicts. The git mas
I know that upon pulling there will be conflicts, but I already know that the repository version is better. How do I resolve all conflicts on the command line with a git command something like $> g
I have a dev branch that hasn't been touched for a while. I merged the trunk into it to integrate many fixes/changes in the main line since it was branched out, but now I have many small conflicts (me
On branch A I had two 'stories', one which I wanted committed to master, one I did not. As these changes were not on feature branches, I needed to separate the two somehow. I used git merge --no-comm
A Git repository has been cloned on several developers' local machines. Some changes have been made to the code in the repository. We're now getting the error: error: Your local changes to the followi
Folks I'm facing repeated code conflicts while pulling from the shared git repo in the following scenario: There is a common svn repository There are several developers who track/sync this common svn
I am currently using JGit to merge remote branches, so after fetching from remote I would like to verify conflicts before I attempt to merge, so that I can decide what kind of merge strategy to use, f
Folks, I'm using i**nternal:merge** tool since I'm not a big fan of GUI diff tools. I really like it and the only thing I find a bit confusing and not quite convenient is its behavior for binary file
CONTEXT: I am preparing a big C# merge using visual studio 2008 and TFS. I need to create a report with the files and the number of collisions (total changes and conflicts) for each file (and in total
There're few question about flattening merge on StackOverflow, with an answer usually being git rebase. These answers though miss one crucial point - order of commits. Suppose there's a branch A w
After a merge failed with some conflicts I can list those with git diff, but git difftool won't display them with the difftool set in the config(in my case Kaleidoscope), instead it will just use norm
I've merged two branches. Got lot's of conflicts. Resolved them all. Now I'm not sure, maybe I've made an error during conflict resolution. And I don't see no another way to check is it true — just ru
I have a situation that I am looking for some guidance on. I have 4 SQL 2008 databases that are syncronized over the internet using merge replication. 1 publisher and 3 subscribers. Normally records
I want to take advantage of the git-merge algorithm on two arbitrary files in a git repo. Here is my working directory: folder/ file1 file2 file1 and file2 are similar, but I want to see how git woul
How can you merge two branches in git, retaining necessary files from a branch? When merging two branches, if a file was deleted in one branch and not in another, the file is ultimately deleted. For e
I've gotten to the point with git that I feel like I know what I'm doing most of the time. I've got local branches for working on features. I rebase periodically and merge between my branches.. I'm sl
I have a branch that is currently at the same commit as master. Another developer has just merged master into their branch and resolved all conflicts, but they have NOT done the opposite yet: merge th
This question may sound silly, and I am pretty much an amateur in git, but does the git merge or git pull command, creates a new branch when there are conflicts?
I found some other questions that talk about a reverse merge in Git, but those questions are asking how to reverse merge an ENTIRE commmit. I want to reverse merge one directory in my tree. Is this po
I'm having difficulty merging from my master branch to a separate branch I've been developing on in quite sometime. Doing a straight forward merge I get the following: shell$ git merge master fatal:
What is the best merge tool for Visual Studio .rc files? It would be nice, if the merge tool could display the resource (e.g. dialog box).
Need a strategy to put Intellij IDEA project files into Git. The main question is how to avoid merge conflicts between branches if idea project files are in git. Another question is it convenient to k
I made three commits on Branch A git checkout Branch B git merge --squash A git commit -m B:merge A into B by squash How can I detect branch A has been merged into B by squash?
I'm quite new to Git so excuse me if I'm using wrong terminology. I created a develop branch off the master branch which I wanted to use for testing fixes/updates. I then created a new branch called t
I'm kind of stumped here. Git appears is both telling me that There are differences between my current branch and the remote branch, and There are no differences between my current branch and the re
I've tried merging two branches on my Git repository and some conflicts occurred on my Storyboard file. Here are the conflicted lines: <resources> <image name=IconAddToCart width=30 heig
To start, I am new to git, but have been eating up documentation and similar issues on the topic like this and this (I will be referring to this latter question later in the post). Summary: I was cher
I'm using Git-Svn to interact with a Svn repository at work and I can't seem to find a way to effectively resolve conflicts for the life of me. I've read the other questions on this topic, but evident
I was using NetBeans GIT plugin before, then I've decided to switch to SourceTree, as it is more efficient and powerful. As a newcomer to SourceTree I've managed to figure out basic Pull, Push and Com
I'm having a very weird problem with git, which I have not seen previously. I'm trying to do git merge --squash feature-branch, but there's a non-conflict in one of the files (there's no actual confli
I like to resolve merge conflicts on the command line, because that way I know exactly what I am doing. This is great for pretty simple merges, but if things get messy, it takes a long time. Are there
Is there a way to completely turn off git's attempts to resolve conflicts before feeding files into 3-way merge tool? I mean those lines: <<<<<<< Temporary merge branch 1 ... ====
Can someone help me on what is the right command that I can use for resolve conflicts for all files under a specific path with --ours strategy? I've tried so far: git checkout --ours public/ git che
For merging I use this to keep mine git merge -X ours foo and this for keep theirs git merge -X theirs foo However on my latest merge it looks best to keep both sides. Does Git have a strategy
I would like to know if there is a way to solve some conflicts (caused by merge or rebase) and send it to another person who will solve the rest of conflicts. It sometimes happens, eg. you work on a b
I have spent a great deal of time since I first started using Git struggling with files being reported as changed when they hadn't been touched, and core.filemode = false resolved those issues... but
I am trying to revert a faulty merge, but the revert changes from both commands do not look right. This is how I made the merge commit: # merge master into branch: git checkout branch git merge master
My Git repository has two files, alpha and beta, with identical content. If I delete alpha in my master branch, and edit it in my feature branch, then when I merge master into feature, I'm warned abou
I'm trying to have two branches with binary files in git - one development and one stable. The development branch can have several changes of these files before I want to release them to the sta
This is not a duplicate of git pull from clean directory has merge conflicts - In that question the user was trying to pull from a remote which had commits which were not in the local branch. In my ca
Could anyone please tell me what the difference between these two commands: git merge --squash and git merge --no-ff
After doing a merge and resolving conflicts, is there an easy way to just accept the default generated commit message from the command line? One of our developers will resolve all the conflicts, and
Is it possible to do a git merge, but without a commit? man git merge says this: With --no-commit perform the merge but pretend the merge failed and do not autocommit, to give the user a chance to
Suppose I have a project on MASTER branch with 100s of php files. To do a bug fixing in the project, i create a separate branch git checkout -b bugfix Then after fixing the bug in 3 files (for eg ind
I have a jQuery Mobile app and the first page has a bunch of controls on it as well as blank areas. I need to detect that the user has touched the screen, anywhere, and move to another page on touch.
I was using the following procedure for a while: git fetch origin master git merge origin/master git push --dry-run origin master git push origin master Now this has stopped working and produces this
I want Git to ignore certain config files during merge. I tried updating git attributes by changing the merge strategy to 'ours' as below. But this works only if there is a merge conflict. http://git-