When recording, sometimes you want to pause the recording, and then continue.
You can set an _idle_time_limit_ in a custom file _/root/.config/asciinema/config_ as follows (this would save you to record the delay times while typing your terminal entries, making the playback 'waiting' times reduced to max. 2 seconds) :
[record]
; Limit recorded terminal inactivity to max n seconds, default: off
idle_time_limit = 2
Recommended to read the docs. about for more info. + other options available.
Hope this helps.
@just4t thanks for the answer. This will help in some cases, but not when i want to actually skip in the recording parts that are printed to the terminal (e.g. booting of a virtual machine).
That's a good use case. We could implement pause/unpause via a keyboard shortcut, for ex: <ctrl-p>
or similar.
It would probably be good to have some indicator/confirmation that you actually paused/unpaused, otherwise you would never be sure.
The only thing I can imagine is that recorder could write play/pause status into some file and we will need to run something like watch -n 1 cat that_file.txt
in separate tab in order to check that status.
But this approach looks kinda ugly...
Maybe we can add this feature as post processing step:
illustration:
+ echo recording...
+ echo still playing...
- echo this pause, it will not be present in final recording file
- echo this line too
+ echo and this line we will keep
- exit
You can set an idle_time_limit in a custom file /root/.config/asciinema/config
Can this be made the default please?
Another workaround would be:
1) Start the recording via asciinema rec my.cast
2) On the part where you want to pause press CTRL+D
to end the recording
3) When you are ready to resume use asciinema rec --append my.cast
Optional: You can edit the recording and e.g. remove certain bits and pieces by editing the my.cast
afterwards with a text-editor
Watching your recording via asciinema play my.cast
should show you a smooth video as if you hit the pause/resume buttons.
Not really, as I don't type with constant speed ;-)
You can "burn" fixed idle time of existing recording by playing it inside new recording.
This one will save idle-time-limit in new recording's header line:
asciinema rec -i 2 -c "asciinema play existing.cast" new.cast
This one will actually adjust the timing of every print event:
asciinema rec -c "asciinema play -i 2 existing.cast" new.cast
I've opened PR #340 for recording pause feature. Please take a look, I think this is what @yuvalif had in mind when opening this issue.
This pause feature if added will be the best.
Sometimes I am not too sure of what I am doing on the terminal (Like reading some docs to learn something), I should be able to pause and resume easily. It's intuitive
Most helpful comment
You can set an _idle_time_limit_ in a custom file _/root/.config/asciinema/config_ as follows (this would save you to record the delay times while typing your terminal entries, making the playback 'waiting' times reduced to max. 2 seconds) :
Recommended to read the docs. about for more info. + other options available.
Hope this helps.