checkpoints.py 744 B

123456789101112131415
  1. """``hermes checkpoints`` subcommand parser."""
  2. from __future__ import annotations
  3. def build_checkpoints_parser(subparsers) -> None:
  4. """Attach the ``checkpoints`` subcommand to ``subparsers``."""
  5. checkpoints_parser = subparsers.add_parser(
  6. "checkpoints", help="Inspect / prune / clear ~/.hermes/checkpoints/",
  7. description="Manage the filesystem checkpoint store — the shadow git "
  8. "repo hermes uses to snapshot working directories before "
  9. "write_file/patch/terminal calls. Lets you see how much "
  10. "space checkpoints occupy, force a prune, or wipe the base.")
  11. from hermes_cli.checkpoints import register_cli as _register_checkpoints_cli
  12. _register_checkpoints_cli(checkpoints_parser)