Output of custom merge driver for Git

149 Views Asked by At

I want to use the custom merge driver for Git. To do this I wrote the program, which takes 5 arguments %O %A %B %L %Pas described here in the block "Defining a custom merge driver" and makes 3-way merge.

  • %O - ancestor’s version
  • %A - current brunch version
  • %B - other branches' version
  • %L - conflict marker size
  • %P - merge driver can learn the pathname in which the merged result will be stored via placeholder %P

And question is which of the five arguments I should use to write the results of the merge? I tried to write as in %A and %P, but it doesn't work.

I also found this:

The merge driver is expected to leave the result of the merge in the file named with %A by overwriting it, and exit with zero status if it managed to merge them cleanly, or non-zero if there were conflicts.

But it also doesn't work. May be i do smth wrong?

0

There are 0 best solutions below