аудит B-02: +76 строк '## Downloads' в 73 карточках (66 без секции + 10 неполных; sec09 ×43, sec06 ×20, sec12 ×7, sec10 ×4, sec08/11 ×1); fix check-md.py: DL_DIR mapping sec09/sec10 (parity-чек был тихо выключен); rename bonus-tfp → 13-bonus-tfp; parser guard +de (Kerényi DTV 1956)
This commit is contained in:
parent
21eba0d135
commit
a05bc9ecc3
43 changed files with 247 additions and 6 deletions
|
|
@ -16,8 +16,11 @@ BANNED_TEXTS = ('// not searched yet', '(not searched yet)', '// not searched',
|
|||
VALID_MARKERS = ('✅', '🔶', '❌', '⬜', '🔎')
|
||||
ORDER = ['ED', 'DL', 'CR', 'NT']
|
||||
|
||||
DL_DIR = {"09-comparison-of-psychodynamic-concepts": "09-comparison",
|
||||
"10-psychopathology-psychiatry": "10-psychopathology"}
|
||||
|
||||
def sec_of(path):
|
||||
return os.path.basename(os.path.dirname(path))
|
||||
return DL_DIR.get(os.path.basename(os.path.dirname(path)), os.path.basename(os.path.dirname(path)))
|
||||
|
||||
def lint_card(path, manifest_files):
|
||||
c = open(path, encoding='utf-8').read()
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ def parse_manifest_files(manifest_path):
|
|||
# sec01/02: table rows | file | size | source | note |
|
||||
for m in re.finditer(r'^\|\s*' + fname_re + r'\s*\|\s*([^|]+)\|\s*([^|]+)\|', c, re.M):
|
||||
f, size, src = m.group(1), m.group(2).strip(), m.group(3).strip()
|
||||
if re.search(r'-(ru|en)[.\-]', f):
|
||||
if re.search(r'-(ru|en|de)[.\-]', f):
|
||||
items.setdefault(f[:2], []).append((f, size, src))
|
||||
# sec03: per-item subsections with bullets
|
||||
for m in re.finditer(r'^### (\d{2}) —.*?\n(.*?)(?=\n### |\n## |\Z)', c, re.M | re.S):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue