|
KiCad PCB EDA Suite
|
CRTP base for libgit2 merge drivers that resolve only the trivial 3-way cases inline and defer real conflicts to the mergetool. More...
#include <kigit_trivial_merge_base.h>
Public Member Functions | |
| KIGIT_TRIVIAL_MERGE_BASE (git_merge_driver_source *aSource, git_buf *aBuf) | |
| int | Merge () |
Static Public Member Functions | |
| static int | Apply (const git_merge_driver_source *aSrc, const char **aPathOut, unsigned int *aModeOut, git_buf *aMergedOut) |
Private Attributes | |
| git_merge_driver_source * | m_mergeDriver |
| git_buf * | m_result |
CRTP base for libgit2 merge drivers that resolve only the trivial 3-way cases inline and defer real conflicts to the mergetool.
Each DERIVED instantiation yields a distinct static Apply() entry point, so the three drivers register as separate libgit2 drivers from one shared Merge() body.
The non-trivial path writes the ours blob through so the working-tree file stays parseable while git records GIT_EMERGECONFLICT.
Definition at line 37 of file kigit_trivial_merge_base.h.
|
inline |
Definition at line 40 of file kigit_trivial_merge_base.h.
References m_mergeDriver, and m_result.
|
inlinestatic |
Definition at line 63 of file kigit_trivial_merge_base.h.
References KIGIT::ApplyMergeDriver().
|
inline |
Definition at line 45 of file kigit_trivial_merge_base.h.
References KIGIT::LoadMergeBlobs(), m_mergeDriver, m_result, KIGIT::MERGE_BLOBS::ours, KIGIT::TryTrivialMerge(), and KIGIT::WriteToGitBuf().
|
private |
Definition at line 70 of file kigit_trivial_merge_base.h.
Referenced by KIGIT_TRIVIAL_MERGE_BASE(), and Merge().
|
private |
Definition at line 71 of file kigit_trivial_merge_base.h.
Referenced by KIGIT_TRIVIAL_MERGE_BASE(), and Merge().