(args: argparse.Namespace)
| 957 | |
| 958 | |
| 959 | def cmd_export(args: argparse.Namespace) -> int: |
| 960 | base_url = args.base_url.rstrip("/") |
| 961 | _require_health(base_url, args.request_timeout) |
| 962 | dest = Path(args.output).expanduser().resolve() |
| 963 | bytes_written = _export_workspace_path(base_url, args.path, args.format, dest, timeout=args.request_timeout) |
| 964 | _json_print({ |
| 965 | "ok": True, |
| 966 | "base_url": base_url, |
| 967 | "workspace_path": args.path, |
| 968 | "export_format": args.format, |
| 969 | "export_path": str(dest), |
| 970 | "bytes_written": bytes_written, |
| 971 | }, compact=args.compact) |
| 972 | return 0 |
| 973 | |
| 974 | |
| 975 | def _iter_images(input_dir: Path) -> list[Path]: |
nothing calls this directly
no test coverage detected