Added demo script
parent
1b951813f4
commit
da997b80c7
|
@ -10,3 +10,4 @@ dist
|
|||
|
||||
# Misc
|
||||
*.gif
|
||||
misc/secrets.sh
|
|
@ -1,11 +1,4 @@
|
|||
# How to use this:
|
||||
# install vhs
|
||||
# enter venv
|
||||
# vhs < misc/demo.tape
|
||||
#
|
||||
# We need macros.lamb, so run this from
|
||||
# the root of this repository.
|
||||
|
||||
# See makedemo.sh
|
||||
|
||||
#Output lambdemo.mp4
|
||||
Output lambdemo.gif
|
||||
|
@ -25,7 +18,7 @@ Enter
|
|||
Sleep 2000ms
|
||||
|
||||
# Demo 1: load
|
||||
Type ":load macros.lamb"
|
||||
Type ":load ../macros.lamb"
|
||||
Sleep 500ms
|
||||
Enter
|
||||
Sleep 2000ms
|
||||
|
|
|
@ -0,0 +1,34 @@
|
|||
#!/bin/bash
|
||||
# Should be run from the misc directory.
|
||||
# Will not work with any other root.
|
||||
|
||||
# Create this file.
|
||||
# Should define two variables:
|
||||
# DAV_USER="name:password"
|
||||
# DAV_URL="https://site.com/dav-path"
|
||||
|
||||
if [[ -f "secrets.sh" ]]; then
|
||||
source secrets.sh
|
||||
else
|
||||
echo "Cannot run without secrets.sh"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Activate venv if not in venv
|
||||
if [[ "$VIRTUAL_ENV" == "" ]]; then
|
||||
source ../venv/bin/activate
|
||||
fi
|
||||
|
||||
# Make sure our venv is running the latest
|
||||
# version of lamb.
|
||||
pip install --editable ..
|
||||
|
||||
|
||||
# Make gif
|
||||
vhs < demo.tape
|
||||
|
||||
# Upload
|
||||
curl \
|
||||
--user $DAV_USER \
|
||||
--url $DAV_URL \
|
||||
--upload-file "lambdemo.gif"
|
Reference in New Issue