canonical / praecepta

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

DOCPR-382: Dates should follow '1 January 1970' format #54

Closed yhontyk closed 3 months ago

yhontyk commented 4 months ago

Added a rule for a date format and a respective test that enforces the date format. I have probably not considered all possible use cases, so the rule should be expanded in the future. Relevant issue: https://warthogs.atlassian.net/browse/DOCPR-382

yhontyk commented 4 months ago

@evilnick I can't make vale to process inline directives in reST without resorting to the raw scope. =\

For example, in the test file, these instances:

12\\24\\1974
12\\30\\1974
1\\31\\1974

are skipped by vale entirely (unless raw source is used, obviously). Any ideas? I have found documentation on how to ignore non-standard markup but not how to make it process elements that it doesn't process by default. If we can't fix it now, I can file this as an issue and follow up on it later. WDYT?

evilnick commented 3 months ago

Okay, I will take another look at this (sorry have been OOO). I am super cautious about adding things which may cause a large number of false positives that we can't easily control. I'll try it out by testing it on some big doc sets and see what happens

evilnick commented 3 months ago

Well, it didn't cause too many problems with the (admittedly limited) tests i did. I think we should merge and open issues for any further refinements needed