0

I am using git for the repo holding source for scientific papers. The .fig files are not mergeable. Can I exclude them from merging? Never add >>>> and <<<<<, ===== to these files ever, the only option is to use one or the other version. (Essentially if merge happens it is done by creating a new file using xfig, etc.)

Matyas
  • 644
  • 6
  • 15
  • Just found another thread solving it. Sorry for the duplicate: [link](http://stackoverflow.com/questions/7994811/git-mark-file-as-binary-to-avoid-line-separator-conversion) – Matyas May 24 '12 at 15:36

1 Answers1

0

The files will be in a conflicted state regardless of whether you include the conflict markers in the file itself. One way or another you'll have to resolve the conflict. Rather than worrying about the conflict markers, you can just discards the contents of the merged file and check out one of the two versions:

git checkout --ours -- my_file.fig

or

git checkout --theirs -- my_file.fig
user229044
  • 232,980
  • 40
  • 330
  • 338
  • Yes, I hoped that I could mark the files accordingly, so that *only* these two choices are offered by git, maybe also allowing the default resolution being "ours" or "theirs" per file. – Matyas May 24 '12 at 15:39
  • I think you can: http://stackoverflow.com/questions/928646/how-do-i-tell-git-to-always-select-my-local-version-for-conflicted-merges-on-a-s – ellotheth May 24 '12 at 15:48