From: Junio C Hamano <gitster@pobox.com>
To: Nicholas Bransby-Williams <nbransby@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: conflict markers in markdown files
Date: Thu, 28 Oct 2021 12:54:57 -0700 [thread overview]
Message-ID: <xmqq5ytgrkku.fsf@gitster.g> (raw)
In-Reply-To: <CAGyLXMBWyfcBVFDRbYJMk+-RjjNBQDvoDeaBtEPiXpUDDTqfOA@mail.gmail.com> (Nicholas Bransby-Williams's message of "Thu, 28 Oct 2021 15:00:08 +0100")
Nicholas Bransby-Williams <nbransby@gmail.com> writes:
> Would it make sense to add an option to merge-file so merge tools can
> specify a custom marker that is statistically much less likely to
> clash with the kinds of text files that are typically stored in git
> repositories?
Is the conflict-marker-size attribute sufficient? If not, why?
In our documentation, we do need to have literal runs of '<<<',
'===', etc. to illustrate and describe the conflict markers, so we
have these in .gitattributes at the top-level:
/Documentation/git-merge.txt conflict-marker-size=32
/Documentation/gitk.txt conflict-marker-size=32
/Documentation/user-manual.txt conflict-marker-size=32
so that the auto-inserted conflict markers will be very long,
instead of just the default (was it 7? I do not remember offhand
because I do not have to). Most importantly, these "32" are written
by folks who wrote these documentation pages and *knew* that there
is no runs of '<', '=', '|' or '>' that are 32 letters long, so it
is safe and can be updated to stay safe when the documentation files
change.
next prev parent reply other threads:[~2021-10-28 19:55 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-28 14:00 conflict markers in markdown files Nicholas Bransby-Williams
2021-10-28 15:38 ` Philip Oakley
2021-10-28 19:54 ` Junio C Hamano [this message]
2021-10-28 20:33 ` Nicholas Bransby-Williams
2021-10-28 22:28 ` Junio C Hamano
2021-10-28 22:49 ` Nicholas Bransby-Williams
2021-10-28 23:11 ` Junio C Hamano
2021-10-28 23:25 ` rsbecker
2021-10-29 5:08 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqq5ytgrkku.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=nbransby@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).