Skip to main content

Amazes your friends by running Python doctests in a fake interactive shell.

Project description

PlayerPiano amazes your friends by running Python doctests in a fake interactive shell.

playerpiano plays back a recorded shell session in a terminal.

recorderpiano can be used to record a shell session for later playback.

Usage

Run playerpiano <options> <FILE>, where FILE is a file containing doctests or the name of a module. Do not pass mymodule.py directly, it will confuse the doctest parser. Use mymodule instead.

Pressing any keys will type source lines, stop at the end of each source block.

Press enter to show the results block.

EOF (^D) will exit the program at the end.

Break (^C) will interrrupt the program immediately.

Options

The --color option will syntax-highlight source lines. It is currently hard-coded for a black background terminal.

The --no-terminal option will disable output on the main terminal. This is less than useful at present.

The --fifo option takes the name of a fifo to duplicate output to. After starting playerpiano with this option, you must run cat name_of_fifo in another terminal before any output will be displayed. This is useful when presenting using a projector. Start a second xterm & run cat, then put it on the overhead (with the main terminal on your laptop). This allows you to see what you’re doing.

Limitations

PlayerPiano only works on Unix-y operating systems, and requires a terminal that speaks VT100. If it works on Windows, please let the author know!

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

PlayerPiano-0.1.1.tar.gz (7.0 kB view details)

Uploaded Source

File details

Details for the file PlayerPiano-0.1.1.tar.gz.

File metadata

  • Download URL: PlayerPiano-0.1.1.tar.gz
  • Upload date:
  • Size: 7.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for PlayerPiano-0.1.1.tar.gz
Algorithm Hash digest
SHA256 b1b6219394e5db76bb096ba6f8ce9dae12c9edc4cb97deeb2a53284e915ec074
MD5 52d8db4730284bffa235ed70fdef348b
BLAKE2b-256 7d1593dd3adfa2549482ce8e0dfbdccce77e3fd36741414739baaa6f4ab9ce12

See more details on using hashes here.

Supported by

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