KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I have the following directory structure: /.git /.git/info/attributes /MyProject /MyProject/pom.xml /MyProject/MyCode.java I have branch master and bugfix. On both branches pom.xml and MyCode.java were modified. i would like to merge changes from bugfix to master only for MyCode.java and keep master version of pom.xml file. So I added "/.git/info/attributes" because i don't want to commit .gitattributes with the project $cat .git/info/attributes pom.xml merge=ours $git status # On branch master nothing to commit (working directory clean) $git check-attr -a pom.xml pom.xml: merge: ours Finally to the problem: When I do: $git merge bugfix Auto-merging MyProject/pom.xml CONFLICT (content): Merge conflict in MyProject/pom.xml Automatic merge failed; fix conflicts and then commit the result. Git is ignoring attributes setting. What am i missing here? I prefer not to define "keepMine.sh" per this post this post is what i need, however i prefer not to go file by file if i have a simple pattern thanks!
Tags (comma-separated)
Save Edits
Cancel