Asciinema

Description

This macro allows to attach asciinema cast-files to a page and play them. Maybe you like it, too.

Based on and inspired by: https://github.com/asciinema/asciinema-player

The github page also documents all the asciinema-player options. (I just snake_cased the options for the plugin).

Installation

  1. Drop the latest release (.js+.css) of the github-repo "asciinema/asciinema-player" into your static files (probably into: "/usr/share/moin/htdocs/asciinema").
  2. Drop the macro in your site-specific "data/plugin/macro" directory.
  3. Restart server.
  4. Attach .cast file to site.
  5. Use macro.

Download & Release Notes

Download

Release Version

Moin Version

Release Notes

Asciinema.py

1.0

1.9 (maybe earlier)

Usage

All options and their order:

<<Asciinema(filename, pagename, theme, cols, rows, autoplay, preload, loop, start_at, speed, poster, font_size, title, author, author_url, author_img_url)>>

Possible values of options

cols=([80]|Num)
rows=([24]|Num)
font-size=([small]|medium|big|Num(px,em,…)
poster=(npt:mm:ss|"data:text/plain,Poster text")
theme=([asciinema]|tango|solarized-dark|solarized-light|monokai)

Example

You can leave out or reorder options if you use assignments (key=value) in the macro call.

<<Asciinema(demo.cast, theme="asciinema", cols=80, rows=24, autoplay=yes, preload=yes, loop=yes, start_at="00:03", speed=2, poster="npt:3", font_size="small", title="Asciinema Demo", author="Name of the Author", author_url="https://moinmo.in/MacroMarket/Asciinema", author_img_url="https://moinmo.in/favicon.ico")>>

MoinMoin Asciinema-Macro: Copyright © 2011-2018 Tobias Stein. GPLv2 or later
Asciinema: Copyright © 2011-2018 Marcin Kulik. All code is licensed under the Apache License, Version 2.0. See LICENSE file for details.

License

MoinMoin Asciinema-Macro: GPLv2 or later
Asciinema: All code is licensed under the Apache License, Version 2.0. See LICENSE file for details.

Bugs

Discussion

MoinMoin: MacroMarket/Asciinema (last edited 2019-07-19 07:57:44 by TobiasStein)