![]() This takes over your terminal session and makes it into the nearest equivalent of the Silver Screen as it's likely ever to be (aside from that time you watched Star Wars in ASCII over telnet). ![]() You can playback your Asciinema using the play subcommand: $ asciinema play mymovie.cast Should you find yourself making lots of edits or belaboring long pauses during the recording, you can install and use the asciinema-edit utility, which can trim out blocks of "footage" by timestamps of your definition, or by eliminating idle time. If you've made a mistake, you can cut the mistake by removing the lines recreating the error. In this example, the resulting file, mymovie.cast is a collection of timestamps and actions that serve as a script (in the sense of a movie script) for the playback mechanism. When you're finished demonstrating how the terminal works, press Ctrl+D or type exit to stop the recording. If you see it in your terminal during recording, it makes the cut. This includes input, output, errors, awkward pauses, mistakes, or successes. Some friendly output alerts you that you're recording, and it tells you how to stop: Press Ctrl+D or just type exit.Įverything you do in your terminal while Asciinema is active gets recorded. To start recording with Asciinema, you use the rec subcommand: $ asciinema rec mymovie.castĪsciinema: recording asciicast to mymovie.castĪsciinema: press or type "exit" when you're done $ sudo bmake install clean Making movies out of text On BSD and any other platform using Pkgsrc: $ cd /usr/pkgsrc/misc/py-asciinema On macOS, you can install using Homebrew: $ sudo brew install asciinema On Debian, Linux Mint, or similar: $ sudo apt install asciinema On Fedora, CentOS, Mageia, or similar: $ sudo dnf install asciinema On Linux, you can install Asciinema using your package manager. You can upload your movie to and share them just as you would any other video on the internet, and you can even embed your movie into a webpage. It saves your "movie" recording to a text file and then replays it on demand. Similar to the script and scriptreplay commands, Asciinema records exactly what your terminal displays. What you might try instead is sending a user a screen recording, but one that they can copy commands from and paste into their own terminal.Īsciinema is an open source terminal session recorder. While it's often easier to just seize control of a user's computer, that's not really the best way to educate. If you've ever been on a support call, you've probably spent several minutes spelling out even the shortest commands and explaining in detail where the spaces and returns fall. It seems to provide support for an window-like border around the actual terminal, and it has a built-in GIF renderer, but I have not tried it.Support calls are important and often satisfying in the end, but the act of clear communication can be arduous for everyone involved. UPDATE: I have recently come across terminalizer. Termscript - it just doesn't work for me, and it freezes my console. ![]() Also, the project hasn't been committed to since 2019. I'm not using this, though, because it's not as portable since you need an existing Ruby installation, and more importantly, it keeps corrupting the active console I'm in, and there's also unpredictable corruption in the recordings. Spielbash - a Ruby project designed specifically to automate asciinema recordings using tmux. Other things I've come across:ĭoitlive - I'm not using this because it's more of a fake-typing automated thing where you actually have to "type like a madman", which could be useful if you're doing a talk in front of an audience but you don't want to mess up your keystrokes, or if you don't want to forget to do certain commands.Īsciiscript - it's written in Go and it works, but you need to compile it yourself, and it also doesn't support waiting for the previous command to finish. The command would look something like asciinema rec -c "./mydemoscript.sh" myrecording. Specifically, I'll be using asciinema for the recording with the -c flag (see here), and demo-magic.sh for the automated typing, since it supports waiting for commands to finish executing (or not) and custom wait times on top of that. What I'm planning on doing for a project I'm in is to use both asciinema as well as demo-magic.sh. I've searched for a lot of solutions for my own projects, and this is the solution that I've come up with: My solution:
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |