You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
648 B
21 lines
648 B
|
2 days ago
|
# -*- coding: utf-8 -*-
|
||
|
|
"""票 05 残留侦察:列出全部「非真实返回」行的文件/行号/原文。"""
|
||
|
|
from __future__ import annotations
|
||
|
|
|
||
|
|
import io
|
||
|
|
import sys
|
||
|
|
from pathlib import Path
|
||
|
|
|
||
|
|
sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding='utf-8')
|
||
|
|
A4 = Path('D:/code/crm-api-docs/A4 客户管理')
|
||
|
|
n = 0
|
||
|
|
for p in sorted(A4.rglob('*.bru')):
|
||
|
|
if p.name == 'folder.bru':
|
||
|
|
continue
|
||
|
|
lines = p.read_text(encoding='utf-8').splitlines()
|
||
|
|
for i, l in enumerate(lines, 1):
|
||
|
|
if '非真实返回' in l:
|
||
|
|
n += 1
|
||
|
|
print(f'{p.relative_to(A4)}:{i}: {l.strip()}')
|
||
|
|
print(f'== 残留行总数 = {n} ==')
|