Skip to main content

Sphinx CLI Recorder

Tests License PyPI version Auto Release

The library is in its early stages!

:::{admonition} TL;DR :class: note

  • 🎥 Record interactions (input & output) with CLI applications
  • 🤖 Automate the recording process via simple Sphinx directives
  • ✔️ Simple; does not require any knowledge of the underlying recording application
  • ⛓️ No dependencies on external services; all files are generated and hosted locally :::

This Sphinx extension is a tool to allow you to easily automate the recording process of CLI applications (without you having to leave your editor 🤯).

Suppose you are developing a neat CLI application, possibly with rich (get it?) visual output. In that case, you put blood, sweat, and tears into the development part but do you want to put the same amount of effort into the documentation? Shouldn't it be easy to show what your CLI application can do? If you record a terminal session to show how to interact with your tool, you need to ensure that the recording is kept up-to-date and doesn't break with future updates. Then you need to know how to upload the file and embed it into your documentation. And all you want to do is to show something cool like:

:autoplay: "True"

Or give the user an example on how to navigate your CLI application:

    - "y"
    - "5"
    - "2"
    - "poodle"
    - "husky"

Or you are looking for a simple way always to include the most recent help text of a tool you are developing.

:rows: 67
:autoplay: "True"

In those cases, it is probably easier to let the Sphinx-CLI-Recorder handle it for you. 😎 It uses asciinema, a text-based terminal recorder under the hood. Utilizing a text-based terminal player has the following advantages:

  • ✅ The output is lossless; no more pixelated videos/images with compression artifacts
  • ✅ No need to wait for huge-video file downloads
  • ✅ The terminal's content can be copied to the clipboard; no need to manually re-type the commands that are shown in a GIF/video

The benefits of using this Sphinx extension are:

  • 🤖 Automates the recording process of asciinema
  • 📅 Ensures that the recordings are always up-to-date
    • 💣 If the code changes and the commands from the documentation fail, no documentation will be built
  • 🏠 Keeps all of your files/data local:
    • 🔐 No need to depend on external services/tokens to upload the recordings
  • 🚅 The recordings are done in parallel to minimize the documentation build time
  • ☑️ Simple; no need to understand how asciinema works

Metadata

Release files for sphinx-cli-recorder 0.1.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for sphinx-cli-recorder 0.1.6
File Size Uploaded
sphinx-cli-recorder-0.1.6.tar.gz 82.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for sphinx-cli-recorder 0.1.6
File Interpreter ABI Platform
sphinx_cli_recorder-0.1.6-py3-none-any.whl Python 3 none any Details

Total release size: 164.5 kB

Release files / sphinx-cli-recorder-0.1.6.tar.gz

Download URL sphinx-cli-recorder-0.1.6.tar.gz
Size 82.8 kB
Tags Source
SHA-256 checksum
How to use checksums
d80aaec7a11a388b2a106cc8e57a8ceacd83a1b2fc2c552db65e450097338d23
BLAKE2b-256 checksum
How to use checksums
0e449e5b2e62e4e5d845963f2953966ca2837b1f3665a92870ae9a061dee71ce
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via pdm/2.1.5 CPython/3.8.14

Release files / sphinx_cli_recorder-0.1.6-py3-none-any.whl

Download URL sphinx_cli_recorder-0.1.6-py3-none-any.whl
Size 81.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
70fc3a7e6091bd3365523b38153edb1fa7381ffeb51c4ddeb303c3862962d084
BLAKE2b-256 checksum
How to use checksums
d034a4ff08979e0a8eb69ecffb85b500e59a707aaafdd21cf7c4934be172ac42
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via pdm/2.1.5 CPython/3.8.14

Release history Release notifications | RSS feed

This release

0.1.6 This release

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page