From: Felipe Contreras Date: Wed, 16 Dec 2020 23:41:51 GMT Subject: Re: [RFC/PATCH] mergetool: use resolved conflicts in all the views Message-ID: <5fda9b3f4979c_973f2083@natae.notmuch> In-Reply-To: Junio C Hamano wrote: > Felipe Contreras writes: > > > It doesn't make sense to display already-resolved conflicts in the > > different views of all mergetools. > > > > We already have the best version in MERGED, with annotations that can > > be used to extract a pruned version of LOCAL and REMOTE. If we are using > > the diff3 conflict-style, we can even extract BASE. > > > > Let's use these annotations instead of using the original files before > > the conflict resolution. > > > > TODO: There may be a better way to extract these files that doesn't rely > > on the user's conflict-style configuration. > > > > See Seth House's blog post [1] for the idea and the rationale. > > > > [1] https://www.eseth.org/2020/mergetools.html > > > > Cc: Seth House > > Signed-off-by: Felipe Contreras > > Hmph, I got what Seth showed, but I do not quite see how the ideas > in the post relate to what this patch does. The patch just avoids > grabbing the contents of each stage out to a file for three stages > using "git checkout-index" and instead does the same by munging the > diff3 output, which ought to have the same information at least for > text files, using "sed", or is there something I am not seeing? It's not quite the same information. Take the following script that uses Seth's example: ---------------------------------------- cat > BASE < LOCAL < REMOTE <