personal memory agent
0

Configure Feed

Select the types of activity you want to include in your feed.

solstone / scripts / export_observer_client_contract_bundle.py
912 B 36 lines
1#!/usr/bin/env python3 2# SPDX-License-Identifier: AGPL-3.0-only 3# Copyright (c) 2026 sol pbc 4 5"""Export the committed observer-client OpenAPI contract bundle.""" 6 7from __future__ import annotations 8 9import argparse 10import sys 11from pathlib import Path 12 13from solstone.convey.contract.observer_bundle_export import ( 14 BundleExportRefused, 15 export_bundle, 16) 17 18ROOT = Path(__file__).resolve().parent.parent 19 20 21def main() -> int: 22 parser = argparse.ArgumentParser(description=__doc__) 23 parser.add_argument("destination", type=Path, help="New destination directory.") 24 args = parser.parse_args() 25 26 try: 27 destination = export_bundle(args.destination, ROOT) 28 except BundleExportRefused as exc: 29 print(str(exc), file=sys.stderr) 30 return 1 31 print(f"exported observer client contract bundle to {destination}") 32 return 0 33 34 35if __name__ == "__main__": 36 raise SystemExit(main())