Skip to content

Commit

Permalink
cleaner
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonathan Dahan committed Jul 25, 2023
1 parent 4658db8 commit 4231cac
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 17 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/vhs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: vhs

on:
push:
paths:
- tapes/functions.tape
jobs:
vhs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: charmbracelet/vhs-action@v1
with:
path: 'tapes/functions.tape'
- uses: stefanzweifel/git-auto-commit-action@v4
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
commit_message: Update generated VHS GIF
branch: main
commit_user_name: vhs-action 📼
commit_user_email: actions@github.com
commit_author: vhs-action 📼 <actions@github.com>
file_pattern: 'tapes/functions.gif'
42 changes: 25 additions & 17 deletions tapes/functions.tape
Original file line number Diff line number Diff line change
Expand Up @@ -10,36 +10,44 @@ Set Height 600
Hide
Type ". $PWD/../geometry.zsh" Enter
Type "setopt interactivecomments" Enter
Type "setopt emacs" Enter
Type "GEOMETRY_PROMPT=(geometry_newline geometry_path geometry_newline geometry_status)" Enter
Type "clear" Enter
Show

Type '# lets define a new function' Sleep 200ms Alt+Enter
Type 'cool() { echo "(~~ cOOl ~~)" }' Sleep 300ms Enter
Type 'cool' Sleep 200ms Enter
Type '# lets define a new function' Sleep 300ms Alt+Enter
Type 'cool() { echo "" }' Sleep 450ms Enter
Type 'cool' Sleep 300ms Enter

Type '# whats in our current PROMPT?' Sleep 200ms Alt+Enter
Type 'echo $GEOMETRY_PROMPT' Sleep 300ms Enter
Type '# whats in our current PROMPT?' Sleep 300ms Alt+Enter
Type 'echo $GEOMETRY_PROMPT' Sleep 450ms Enter

Type '# lets add our cool function to the left' Sleep 200ms Alt+Enter
Type 'GEOMETRY_PROMPT+=(cool)' Sleep 300ms Enter
Sleep 1s

Type '# <-- look! its now in our prompt!' Sleep 200ms Alt+Enter
Type '# but what if we have a slow function?' Sleep 200ms Alt+Enter
Type '# lets add our cool function to the left' Sleep 300ms Alt+Enter
Type 'GEOMETRY_PROMPT+=(cool)' Sleep 450ms Enter

Type 'snail() { sleep 3; echo "@_. "}' Sleep 300ms Enter
Type 'snail' Enter Sleep 3s
Type '# <- look! its now in our prompt!' Sleep 300ms Enter
Sleep 1s

Type '# the right prompt runs commands in the background' Sleep 200ms Alt+Enter
Type '# so your shell always stays responsive' Sleep 200ms Alt+Enter
Type 'GEOMETRY_RPROMPT+=(snail)' Sleep 300ms Enter
Type 'ls' Sleep 300ms Enter
Type '# but what if we have a slow function?' Sleep 300ms Alt+Enter

Type@333ms '1..2..3..'
Type 'snail() { sleep 4; echo "@_. "}' Sleep 450ms Enter
Type 'snail' Enter
Sleep 4s

Type '# the right prompt runs commands in the background' Sleep 300ms Alt+Enter
Type '# so your shell always stays responsive' Sleep 300ms Alt+Enter
Sleep 1s
Type 'GEOMETRY_RPROMPT+=(snail)' Enter

Type@300ms '# 1..2..3..'
Hide
Type '# hello snail! ->' Alt+Enter
Type@5ms ' hello snail! ->'
Show

Sleep 4s Alt+Enter Alt+Enter

Type "git clone https://github.com/geometry-zsh/geometry"

Sleep 5s

0 comments on commit 4231cac

Please sign in to comment.