mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2026-04-25 17:26:22 +03:00
[GH-ISSUE #58] spurious warnings about question or exclamation marks in a header #1894
Labels
No labels
bug
enhancement
enhancement
enhancement
fixed in next
fixed in next
fixed in next
new rule
new rule
new rule
pull-request
question
refactoring
refactoring
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/markdownlint#1894
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @wbolster on GitHub (May 5, 2017).
Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/58
a header like this one:
produces a
MD026warning about trailing punctutation in the header. the same happens when an exclamation mark is used.this should not happen.
@DavidAnson commented on GitHub (May 5, 2017):
What do you think is wrong here?
The documentation for
MD026explicitly calls out that it will trigger for?and!:https://github.com/DavidAnson/markdownlint/blob/master/doc/Rules.md#md026---trailing-punctuation-in-header
If you do not like this rule, it can be disabled completely - or you can edit the list of characters it looks for (again, see documentation above).
@wbolster commented on GitHub (May 6, 2017):
what i think is wrong here is that the defaults are not sensible enough. :)
having a question mark at the end of a header is quite common (e.g. faqs), and requiring explicit configuration for it seems backwards to me.
@DavidAnson commented on GitHub (May 6, 2017):
Fair enough. :) For what it's worth, this rule came from the Ruby implementation. I'll admit it's not my absolute favorite rule, but I think it's a good guideline in general, it's easy to turn off if you don't want it, and it's easy to customize when needed. I'm not inclined to break compatibility with the Ruby implementation over something like this, so unless you find that the rule is behaving wrongly, I will recommend turning it off. Sorry for the inconvenience!
@wbolster commented on GitHub (May 6, 2017):
yeah i understand you took the rules from another project (unsure why there are 2 implementations though), but i was not aware that you aim for keeping those rules unchanged, even when they do not make sense as defaults.
thanks for the explanation.
@petk commented on GitHub (Apr 21, 2019):
Hello, worth noting, that headings in writings can include question marks an exclamation marks. Yes, one of the more strange settings.