Files
vpn-dns-gateway/demo/ci/reset-output.py
vsun1 27b82c169e
vpn-dns-gateway/pipeline/head This commit looks good
vpn-dns-gateway/pipeline/pr-main This commit looks good
Add frozen TikZRefinery demo baseline and build pipeline
2026-11-25 22:46:33 -05:00

16 lines
634 B
Python

"""Clear per-run staging outputs, retaining compiler/report caches and archived runs."""
from pathlib import Path
import shutil
root = Path.cwd().resolve()
assert (root / 'demo/snapshot.json').is_file(), 'Run from the demo repository root'
for name in ('artifacts', 'reports'):
target = root / 'build/demo' / name
resolved = target.resolve()
assert not target.is_symlink() and resolved == root / 'build/demo' / name
assert resolved.is_relative_to(root / 'build/demo')
if target.exists():
shutil.rmtree(target)
target.mkdir(parents=True)
print('Fresh per-run artifacts/reports; build caches retained')