canonical / praecepta

Creative Commons Attribution Share Alike 4.0 International
12 stars 20 forks source link

Rule 13 (spell out numbers below 10) should ignore numbers that contain punctuation #51

Closed userMaximilian closed 4 months ago

userMaximilian commented 4 months ago

Hello!

Rule 13 currently generates warnings for single digits that are preceded and/or followed by punctuation, such as in:

The warnings generated also sometimes differ if the number is at the start and/or end of a line. For example, Vale warns on each digit in the line "Test 6.6.0\n", but only the last two digits in the line "6.6.0\n".

I'm happy to help with preparing a PR or testing as needed, if that would be helpful.

SecondSkoll commented 4 months ago

You are quite correct. This should be solvable with a negative lookbehind and an alteration to the existing negative lookahead. It should be a relatively easy fix. Thanks!

SecondSkoll commented 4 months ago

Resolved with #53