19 lines
543 B
Python
19 lines
543 B
Python
#!/usr/bin/env python3
|
|
"""批量跑 strip_page.py"""
|
|
import subprocess, os
|
|
|
|
base = '/Users/bigemon/WorkSpace/vr-shopxo-plugin/参考-秀动'
|
|
stripper = '/Users/bigemon/WorkSpace/vr-shopxo-plugin/strip_page.py'
|
|
|
|
files = [f for f in os.listdir(base) if f.endswith('.html')]
|
|
files.sort()
|
|
|
|
for f in files:
|
|
inp = os.path.join(base, f)
|
|
print(f'>>> 处理: {f}')
|
|
r = subprocess.run(['python3', stripper, inp, base], capture_output=True, text=True)
|
|
print(r.stdout)
|
|
if r.stderr:
|
|
print('STDERR:', r.stderr[:300])
|
|
print()
|