hty export
Convert a recorded session log into a share-ready artifact and write it to stdout. Currently supports asciinema v2 .cast files, which can be rendered to a GIF with agg or vhs, played with asciinema play, or uploaded to asciinema.org.
Unlike hty replay, which re-renders a session live in your terminal, hty export produces a portable file you can embed in docs, attach to a bug report, or hand to a reviewer who doesn’t have hty installed.
Reference
hty export [SESSION] --format FMT
Convert a recorded session log to a share-ready artifact and write it
to stdout. SESSION may be a --name, a full UUID, or any unambiguous
prefix; if omitted and exactly one log exists, that one is used.
Flags:
--format FMT Output format. Required. Supported:
asciicast asciinema v2 .cast — pipe into `agg`,
`vhs`, or upload to asciinema.org.
Example:
hty export my-session --format asciicast > run.cast
agg run.cast run.gif
Examples
# Export to asciinema .cast
hty export my-session --format asciicast > run.cast
# Render a GIF with agg
hty export my-session --format asciicast | agg - run.gif
# Upload to asciinema.org
hty export my-session --format asciicast > run.cast
asciinema upload run.casthty export reads the on-disk session log, so it works on exited sessions just like hty logs and hty replay. Use hty delete to remove the log once you’ve exported what you need.
Last updated on