cleanup: one coherent layout; workflow consumes only the frozen CLI
extension-conformance / conformance (push) Canceled after 0s

This commit is contained in:
Marqdo Extension Fixtures committed 2026-11-21 23:47:03 +08:00
1 parent 978a6fe080
commit b729afc5b1
12 files changed
+13 -917

No files matched your search

-28
View File
@@ -1,28 +0,0 @@
#!/usr/bin/env python3
"""Refresh the SHA-256 pin in kernel/kernel.json from kernel/mocklang.
This script is for fixture maintainers only. Tests never rewrite the fixture;
they read the committed digest and fail if it no longer matches.
"""
import hashlib
import json
import pathlib
import sys
ROOT = pathlib.Path(__file__).resolve().parent.parent
KERNEL = ROOT / "kernel"
def main() -> int:
mocklang = KERNEL / "mocklang"
descriptor = KERNEL / "kernel.json"
digest = hashlib.sha256(mocklang.read_bytes()).hexdigest()
data = json.loads(descriptor.read_text(encoding="utf-8"))
data["digest"] = digest
descriptor.write_text(json.dumps(data, indent=2, ensure_ascii=False) + "\n", encoding="utf-8")
print(f"kernel.json digest = {digest} ({mocklang.name})")
return 0
if __name__ == "__main__":
sys.exit(main())