Crates.io | autocast |
lib.rs | autocast |
version | 0.1.0 |
source | src |
created_at | 2023-07-20 06:29:26.256833 |
updated_at | 2023-07-20 06:29:26.256833 |
description | Automate terminal demos |
homepage | |
repository | https://github.com/k9withabone/autocast |
max_upload_size | |
id | 921064 |
size | 942,535 |
A tool to help automate the creation of terminal demos. Automatically generate an asciicast file for use with asciinema.
Demo created with autocast, see demo.yaml. The demo is also viewable on asciinema.
cargo binstall autocast
.cargo install autocast
.$ autocast -h
Automate terminal demos
Usage: autocast [OPTIONS] <IN_FILE> <OUT_FILE>
Arguments:
<IN_FILE> Input file to create the asciicast file with
<OUT_FILE> Output asciicast file
Options:
--width <WIDTH>
Terminal width
--height <HEIGHT>
Terminal height
-t, --title <TITLE>
Title of the asciicast
--shell <SHELL>
Shell to use for running commands [default: bash] [possible values: bash, python]
-e, --environment <NAME=VALUE>
Environment variables to use in the shell process
--environment-capture <ENV_VAR>
Environment variables to capture [default: TERM] [aliases: env-cap]
-d, --type-speed <TYPE_SPEED>
Default time between key presses when writing commands [default: 100ms] [aliases: delay]
--prompt <PROMPT>
The shell prompt to use in the asciicast output [default: "$ "]
--secondary-prompt <SECONDARY_PROMPT>
The shell secondary prompt to use in the asciicast output [default: "> "]
--timeout <TIMEOUT>
Maximum amount of time to let a shell command run before returning with an error [default: 30s]
--overwrite
Overwrite output file if it already exists
-h, --help
Print help (see more with '--help')
-V, --version
Print version
Use autocast --help
to see a more in-depth explanation of the CLI arguments. Also see their corresponding settings in full-example.yaml.
Non-default CLI arguments will override settings specified in the input YAML file.
For examples, see example.yaml and demo.yaml. For an in-depth explanation of all configuration values, see full-example.yaml.
Instruction Kinds:
Contributions/suggestions are very welcome and appreciated! Feel free to create an issue, discussion, or pull request. Especially in need of default configurations for other shells (zsh, fish, etc.) as I have no experience with shells other than bash.
Session
and ReplSession
in ShellSession
) for autocast's needs.Autocast is licensed under the GNU General Public License v3.0 or later, see the license file for details.