Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automate terminal recordings for documentation #53

Open
mikaelmello opened this issue Apr 9, 2022 · 1 comment
Open

Automate terminal recordings for documentation #53

mikaelmello opened this issue Apr 9, 2022 · 1 comment

Comments

@mikaelmello
Copy link
Owner

Is your feature request related to a problem? Please describe.

Generating each recording is a boring process with a lot of manual changes required. The recordings are even a bit outdated on functionality just because I didn't want to re-record everything which would require a lot of time.

Describe the solution you'd like

Have a set of recordings each containing the example to run and a series of keystrokes to perform.

Then automatically run these examples with the provided keystrokes, recording the terminal output and generating .cast and .gif outputs.

Describe alternatives you've considered

I thought of recording the keystrokes to give it a more natural feel but sometimes that's worse. For example when the recorder (I) take too long for the next action or type too fast worsening UX. Executing the keystrokes at a constant interval seems good enough.

@mikaelmello mikaelmello added this to the v1.0.0 milestone Aug 19, 2022
@b3nj5m1n
Copy link
Contributor

Just in case you're not already aware of it, vhs was made for exactly this.

Here's a quick example:

Sleep 1s
Type 'cargo run --example date --features "date macros"'
Sleep 1s
Enter
Set TypingSpeed 1s
Sleep 1s
Type "KKKKKKK"
Sleep 500ms
Type "HHHHHjjhh"
Enter
Sleep 1.5s
Escape
Sleep 500ms
Escape 3
Sleep 500ms
vhs < demo.tape

out

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants