Skip to main content

CLI utility to automate asciinema

Project description

https://badge.fury.io/py/asciinema-automation.svg https://github.com/PierreMarchand20/asciinema_automation/actions/workflows/CI.yml/badge.svg

asciinema-automation is a Python package which provides a small CLI utility to automate asciinema recordings. The only dependencies are asciinema and Pexpect.

Recording is made easier by:

  • making the live recording for you, to get the perfect take in one go (no more missed keys!),

  • while looking not too robotic by adding Gaussian delay between keystrokes.

One specificity of this package is that

  • it makes automated recording as reproducible and robust as possible. In particular, there is no need to add a manually set waiting time between commands to wait for previous outputs.

To that end, you can write the commands you wish to showcase in a text file, and using comment lines starting by #$ (see examples folder and example), you can specify the expected output of each command, and/or change the configuration of the automated recording on-the-fly.

Example

Demo

This example is generated reading with asciinema-automation a script that calls asciinema-automation which reads the hello_world.sh example in this repository 🙃

Numerous examples can also be found here.

Installation

You can use pip to install:

python3 -m pip install asciinema-automation

Or you can install it directly using this GitHub repository. In this case, you need to call git clone to recover the source code of this repository

git clone https://github.com/PierreMarchand20/asciinema_automation.git

and then call pip in your local folder of this repository to install this package and its dependencies

pip3 install .

History

This repository is inspired by asciiscript, which is not maintained any more. I first made a fork, but being not very familiar with go, I preferred to rewrite everything in python.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

asciinema_automation-0.2.1.tar.gz (7.9 kB view details)

Uploaded Source

Built Distribution

asciinema_automation-0.2.1-py3-none-any.whl (8.1 kB view details)

Uploaded Python 3

File details

Details for the file asciinema_automation-0.2.1.tar.gz.

File metadata

  • Download URL: asciinema_automation-0.2.1.tar.gz
  • Upload date:
  • Size: 7.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.4

File hashes

Hashes for asciinema_automation-0.2.1.tar.gz
Algorithm Hash digest
SHA256 baaca43f2c87c47d07c2ebdd821068e0e27b323c5e69a64c356863e68c1281fd
MD5 fc3ef4ca8d855d13bbffe27a24c01a8b
BLAKE2b-256 67b20d33b4a22d4a0ca5f8c46a0f6ba8ca22c35aab1dbb2cc5c2381c2fb4318c

See more details on using hashes here.

File details

Details for the file asciinema_automation-0.2.1-py3-none-any.whl.

File metadata

File hashes

Hashes for asciinema_automation-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 14c7d9b7f234f08d47ddfeca71c729df543bc1aa456eafb2267d720632e0443e
MD5 0b6815667b3aab546aecaefb882301f6
BLAKE2b-256 ebfff880e5c98fd2c6634576b0b9457b9a41f3b02c5b027b7917cbc1187ae71a

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page