What are the filenames in Conflict Solver?

3 views
Skip to first unread message

Eric B

unread,
Jun 18, 2021, 9:46:06 AMJun 18
to smar...@googlegroups.com
Hi,

I am using an external tool for conflict resolution, and have defined the command as follows:

C:\dev\tools\Beyond Compare 4\BComp.exe "${leftFile}" "${rightFile}" "${baseFile}" /mergeoutput="${mergedFile}"


So this works fine - I see the 3 files open in Beyond Compare and can do the manual resolution.

However, I do not understand the filenames that are displayed.  I see the following:

  • C:\Users\erbe\AppData\Local\Temp\smartgit13579396736398473075\conflict-solver_ProcessorHelper-ours-_11406947687241154103_.java
  • C:\Users\erbe\AppData\Local\Temp\smartgit13579396736398473075\conflict-solver_ProcessorHelper-base-_3273769207617117761_.java
  • C:\Users\erbe\AppData\Local\Temp\smartgit13579396736398473075\conflict-solver_ProcessorHelper-theirs-_6439531555393980664_.java

I initially thought that the  _11406947687241154103_ suffix was the commitId, but I cannot find that commit ID anywhere in my tree.

Is that just a random number?  Is there a way to append the commitId to the filename?  Would make it easier sometimes to identify which commit theirs vs ours vs base is coming from.

What is the baseFile supposed to represent?  Is it supposed to be the merge-base between the two commits?  If I find the merge base between the 2 commits causing the conflict, it does not match the "baseFile".

Thanks,

Eric

syntevo Support

unread,
Jun 21, 2021, 4:13:49 AMJun 21
to smar...@googlegroups.com
> Is that just a random number?

That's correct: it results from calling Java's API to create a unique file (atomically).

> Is there a way to append the commitId to the filename?

That should be possible, though only in addition to the unique number. I have scheduled this as SG-14589.

> What is the baseFile supposed to represent? Is it supposed to be the
> merge-base between the two commits? If I find the merge base between the 2
> commits causing the conflict, it does not match the "baseFile".

It should be the merge base. It's the content of the blob which is referenced in the .git/index in stage "1":

https://stackoverflow.com/questions/44754810/git-get-ours-theirs-file-content-during-merge

--
Best regards,
Marc Strapetz
syntevo GmbH
http://www.syntevo.com



06/18/2021 15:47 - Eric B wrote:

> Hi,
>
> I am using an external tool for conflict resolution, and have defined the
> command as follows:
>
> C:\dev\tools\Beyond Compare 4\BComp.exe "${leftFile}" "${rightFile}"
> "${baseFile}" /mergeoutput="${mergedFile}"
>
>
> So this works fine - I see the 3 files open in Beyond Compare and can do
> the manual resolution.
>
> However, I do not understand the filenames that are displayed. I see the
> following:
>
>
> -
> C:\Users\erbe\AppData\Local\Temp\smartgit13579396736398473075\conflict-solver_ProcessorHelper-ours-_11406947687241154103_.java
> -
> C:\Users\erbe\AppData\Local\Temp\smartgit13579396736398473075\conflict-solver_ProcessorHelper-base-_3273769207617117761_.java
> -
> C:\Users\erbe\AppData\Local\Temp\smartgit13579396736398473075\conflict-solver_ProcessorHelper-theirs-_6439531555393980664_.java
>
>
> I initially thought that the _11406947687241154103_ suffix was the
> commitId, but I cannot find that commit ID anywhere in my tree.
>
> Is that just a random number? Is there a way to append the commitId to the
> filename? Would make it easier sometimes to identify which commit theirs
> vs ours vs base is coming from.
>
> What is the baseFile supposed to represent? Is it supposed to be the
> merge-base between the two commits? If I find the merge base between the 2
> commits causing the conflict, it does not match the "baseFile".
>
> Thanks,
>
> Eric
>
> --
> You received this message because you are subscribed to the Google Groups
> "SmartGit" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
> smartgit+u...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/smartgit/CA%2BT%2BPjH0x-0aF7ysH2sKGiF3hqcpkpJb%2BedEuK9hwNW%2B2BjZWQ%40mail.gmail.com.
>
Reply all
Reply to author
Forward
0 new messages