This patch changes the regex to also match directives
which start with whitespace.
Closes-Bug: #1487302
Change-Id: I4c3168228164d865cc31dfd24160c41267aeb016
When sphinx (and by association restructuredtext-lint)
finds an error with say a anonymous backref it does not
include the line number (it defaults to none); so in this
case covert that line number to ? and output that as the
line number in the output shown to the user.
Change-Id: I013857cdb6a24cf11d94265358b8294dfed0236d
Instead of having a implicitly defined constant that doesn't
explain why the value was set use a documented frozenset that
has the valid docutils messaging levels with links/comments to
describe why they are being used.
Change-Id: I372c1babfb02c33b5881e2e6a12d464f75d944f7
When a check is for a rst file vs a plaintext
file and is not interoperable this change allows
that check to declare that it only knows how to
scan certain files.
It also fixes the max line checker to use a similar
routine to differentiate between rst files and non
rst files and uses a different routine based on this
decision.
Change-Id: I1e3e5f9f1631ed5babe2df17c987e8e872938a38
To allow for any future additions to be added that are not
just prefix matches lets switch the prefix match array for
sphinx false positives to using regex instead.
Change-Id: I7ec0188d1fee98dbafb5b99429f96982a2be261c
When doc8 scans rst files with sphinx specific roles
and references it is unable to determine what those roles
are and then complains that these false positives are
actual errors.
To avoid these types of false positives add a option that
can be provided when running on files that may contain these
types of errors to allow them to be skipped/ignored.
Change-Id: Ia6896617534f68e517d5996d53cf2de274507f56
I think PEP 0263 (http://legacy.python.org/dev/peps/pep-0263/) is
not used anywhere else and so it should be removed when it's not
needed.
Change-Id: I013bf7f1df485d79b4cf17b874bfb22a0b920f2b