1
1
mirror of https://github.com/wez/wezterm.git synced 2024-12-18 02:42:05 +03:00
wezterm/wt-replay

24 lines
423 B
Plaintext
Raw Normal View History

2019-03-18 09:34:05 +03:00
#!/bin/bash
# Replays a recorded session
TRANSCRIPT="$1"
if test -z "$TRANSCRIPT" -o ! -f "$TRANSCRIPT" ; then
echo "usage: wt-replay TRANSCRIPT.tgz"
exit 1
fi
WHERE=`mktemp -d`
tar xzf "$TRANSCRIPT" -C $WHERE
echo "--- Starting replay ---"
2019-03-18 09:34:05 +03:00
case $OSTYPE in
darwin*)
script -p $WHERE/*.typescript
;;
linux*)
scriptreplay $WHERE/*.timing $WHERE/*.typescript
;;
esac
echo "--- replay complete ---"