Record your terminal window using asciinema

Here's a quick tutorial how to use asciinema to record a cast of your terminal window so you can play it back in your terminal or embed it on a web page. This is great if you want to create tutorials or show how a product works.

Installation

Install it using brew on a Mac with brew install asciinema

Recording

You can record and upload to asciinema.org by typing asciinema rec, but if you want to record offline you can append an output file.

asciinema rec my.cast

Playing back

To play back your recording in your terminal, simply run:

asciinema play my.cast

Embedding in a web page

If you want to self host, then there is a standalone web player. You can download the JavaScript and CSS from the releases page:

asciinema/asciinema-player
Web player for terminal session recordings ⏩. Contribute to asciinema/asciinema-player development by creating an account on GitHub.

Demonstration

Here's a quick demo of what a recording looks like when playing back.

And here's my lazy embedded HTML code to put it in this blog.

<link rel="stylesheet" type="text/css" href="https://medatech.github.io/asciinema-player.css" />

<asciinema-player src="https://medatech.github.io/demo.cast"></asciinema-player>

<script src="https://medatech.github.io/asciinema-player.js"></script>

Subscribe to Martin Adams | Building Flowtelic

Don’t miss out on the latest issues. Sign up now to get access to the library of members-only issues.
jamie@example.com
Subscribe

The most efficient note-taking app!

I'm building Flowtelic to help you study, learn, think, write and publish with maximum efficiency and consistency. Interested? Join the waitlist!