Re: [PATCH v3 05/11] rerere: add documentation for conflict normalization
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jul 30, 2018, 17:50 UTC
- Message-ID
- <xmqqin4whatr.fsf@gitster-ct.c.googlers.com>
- In-Reply-To
- <20180714214443.7184-6-t.gummerer@gmail.com>
Thomas Gummerer <t.gummerer@gmail.com> writes:
> +Different conflict styles and branch names are normalized by stripping > +the labels from the conflict markers, and removing extraneous > +information from the `diff3` conflict style. Branches that are merged
s/extraneous information/commmon ancestor version/ perhaps, to be fact-based without passing value judgment?
We drop the common ancestor version only because we cannot normalize from `merge` style to `diff3` style by adding one, and not because it is extraneous. It does help humans understand the conflict a lot better to have that section.
> +By extension, this means that rerere should recognize that the above > +conflicts are the same. To do this, the labels on the conflict > +markers are stripped, and the diff3 output is removed. The above
s/diff3 output/common ancestor version/, as "diff3 output" would mean the whole thing between <<< and >>> to readers.
Show 15 quoted lines
> diff --git a/rerere.c b/rerere.c
> index be98c0afcb..da1ab54027 100644
> --- a/rerere.c
> +++ b/rerere.c
> @@ -394,10 +394,6 @@ static int is_cmarker(char *buf, int marker_char, int marker_size)
> * and NUL concatenated together.
> *
> * Return the number of conflict hunks found.
> - *
> - * NEEDSWORK: the logic and theory of operation behind this conflict
> - * normalization may deserve to be documented somewhere, perhaps in
> - * Documentation/technical/rerere.txt.
> */
> static int handle_path(unsigned char *sha1, struct rerere_io *io, int marker_size)
> {Thanks for finally removing this age-old NEEDSWORK comment.