-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Labels
featureNew functionalityNew functionality
Description
Clarification and motivation
Imagine the following list of links:
[file](files/file.out)
[file2](files/file2.out)
[file3](files/file3.out)
[Another file](files/another-file.out)
[And a file once again](files/and-a-file-once-again.out)
It is easy to make a mistake here during copy-pasting so that text is updated and the link is not. I think we can use some heuristics to spot such mistakes (but avoid false positives at all costs):
- If this check is enabled in config (it should be by default);
- And there are two links
[T1](L1)
and[T2](L1)
in a file, andT1
is substring ofL1
modulo casing and all the non-alphanum characters, whileT2
is not substring ofL1
modulo the same things;
then report an error at [T2](L1)
position, mentioning that it could be a bad copy-paste of [T1](L1)
. And a similar check for [T1](L2)
.
Acceptance criteria
- The check is implemented.
- It can be disabled both in config and in place via some
<--! xrefcheck: no duplication check in {file/paragraph/link} -->
.
Metadata
Metadata
Assignees
Labels
featureNew functionalityNew functionality