Skip to content

Commit

Permalink
Split demo video tape files
Browse files Browse the repository at this point in the history
The application VHS is used to record the demo videos. A new feature
was added that allowed for the tape files to be sourced from other
files. This allowed for a more modular approach to build the videos.

As part of the change to the modular components, some of the tape logic
was modified. This was especially apparent for hidden sections where
the process had significantly shorter wait times. As these components
are now shared, they need to use the original visible wait times. This
slows down the video creation.

It was not possible to add the video dimensions to the init tape as
this introduced a bug with incorrect margins. Other settings were able
to be migrated to this file.

As all recording is done within a Docker container, the shell was
unnecessarily set and has been removed.
  • Loading branch information
mikelorant committed Jan 3, 2024
1 parent 56617fc commit 5f0517d
Show file tree
Hide file tree
Showing 12 changed files with 79 additions and 152 deletions.
4 changes: 2 additions & 2 deletions public/videos/before-you-start.webm
Git LFS file not shown
4 changes: 2 additions & 2 deletions public/videos/do-the-change-feature1.webm
Git LFS file not shown
4 changes: 2 additions & 2 deletions public/videos/do-the-change-feature2.webm
Git LFS file not shown
4 changes: 2 additions & 2 deletions public/videos/do-the-change-new-commits.webm
Git LFS file not shown
23 changes: 7 additions & 16 deletions scripts/video/tapes/before-you-start.tape
Original file line number Diff line number Diff line change
@@ -1,15 +1,10 @@
Output ../../assets/videos/before-you-start.webm
Output ../../public/videos/before-you-start.webm

Set Shell "bash"
Set FontSize 18
Set Width 1050
Set Height 700

Require docker
Source tapes/sources/init.tape

Hide

Type "docker-compose run demo" Enter Sleep 1
Type "git reset --hard HEAD~" Enter Sleep 0.25
Type "git switch -c fix/JIRA-123_update-data" Enter Sleep 0.25
Type "vim .data" Enter Sleep 0.25
Expand All @@ -20,21 +15,17 @@ Escape
Type "ZZ"
Type "touch file" Enter Sleep 0.25

Ctrl+L Sleep 0.25

Show
Ctrl+L

Sleep 1
Show Sleep 1

Type "git status" Enter Sleep 3
Type "git stash -u" Sleep 1s Enter Sleep 3
Type "git switch main" Enter Sleep 3
Type "git pull" Enter Sleep 3

Ctrl+L Sleep 1
Type "git status" Enter Sleep 3
Ctrl+L Sleep 1

Hide
Type "git status" Enter Sleep 3

Ctrl+D Sleep 0.25
Ctrl+D
Source tapes/sources/terminate.tape
37 changes: 5 additions & 32 deletions scripts/video/tapes/do-the-change-feature1.tape
Original file line number Diff line number Diff line change
@@ -1,44 +1,17 @@
Output ../../assets/videos/do-the-change-feature1.webm
Output ../../public/videos/do-the-change-feature1.webm

Set Shell "bash"
Set FontSize 18
Set Width 1050
Set Height 700

Require docker
Source tapes/sources/init.tape

Hide
Show Sleep 1

Type "docker-compose run demo" Enter Sleep 1

Ctrl+L Sleep 0.25

Show

Sleep 1

Type "git switch -c feature1" Enter Sleep 1
Type "vim .data" Enter Sleep 1
Type "6Go" Sleep 0.25
Type "SEPARATOR #2.5" Enter
Type "CHANGE" Sleep 1
Escape
Type "ZZ" Sleep 1

Type "git add -p" Enter Sleep 3
Type "y" Sleep 1 Enter Sleep 1

Type "git commit" Sleep 1 Enter
Type "i" Sleep 0.25
Type "Add feature1" Sleep 1
Escape
Type "ZZ" Sleep 3
Source tapes/sources/git-commit-feature1.tape

Ctrl+L Sleep 0.25

Type "git show -p" Sleep 1 Enter Sleep 3

Hide

Ctrl+D Sleep 0.25
Ctrl+D
Source tapes/sources/terminate.tape
55 changes: 7 additions & 48 deletions scripts/video/tapes/do-the-change-feature2.tape
Original file line number Diff line number Diff line change
@@ -1,55 +1,17 @@
Output ../../assets/videos/do-the-change-feature2.webm
Output ../../public/videos/do-the-change-feature2.webm

Set Shell "bash"
Set FontSize 18
Set Width 1050
Set Height 700

Require docker
Source tapes/sources/init.tape
Source tapes/sources/git-commit-feature1.tape

Hide
Ctrl+L

Type "docker-compose run demo" Enter Sleep 1
Show Sleep 1

Type "git switch -c feature1" Enter Sleep 0.25
Type "vim .data " Enter Sleep 0.25
Type "6Go" Sleep 0.25
Type "SEPARATOR #2.5" Enter
Type "CHANGE" Sleep 0.25
Escape
Type "ZZ" Sleep 0.25

Type "git add -p" Enter Sleep 0.25
Type "y" Sleep 0.25 Enter Sleep 0.25

Type "git commit" Sleep 0.25 Enter
Type "i" Sleep 0.25
Type "Add feature1" Sleep 0.25
Escape
Type "ZZ" Sleep 0.25

Ctrl+L Sleep 0.25

Show

Sleep 1

Type "git switch -c feature2" Enter Sleep 1
Type "vim .data" Enter Sleep 1
Type "14Go" Sleep 0.25
Type "SEPARATOR #5.5" Enter
Type "CHANGE" Sleep 1
Escape
Type "ZZ" Sleep 1

Type "git add -p" Enter Sleep 3
Type "y" Sleep 1 Enter Sleep 1

Type "git commit" Sleep 1 Enter
Type "i" Sleep 0.25
Type "Add feature2" Sleep 1
Escape
Type "ZZ" Sleep 3
Source tapes/sources/git-commit-feature2.tape

Ctrl+L Sleep 0.25

Expand All @@ -60,7 +22,4 @@ Ctrl+L Sleep 0.25
Type "git branch" Sleep 1 Enter Sleep 3
Type "git log --oneline -2" Sleep 1 Enter Sleep 3

Hide

Ctrl+D Sleep 0.25
Ctrl+D
Source tapes/sources/terminate.tape
55 changes: 7 additions & 48 deletions scripts/video/tapes/do-the-change-new-commits.tape
Original file line number Diff line number Diff line change
@@ -1,57 +1,19 @@
Output ../../assets/videos/do-the-change-new-commits.webm
Output ../../public/videos/do-the-change-new-commits.webm

Set Shell "bash"
Set FontSize 18
Set Width 1050
Set Height 700

Require docker

Hide

Type "docker-compose run demo" Enter Sleep 1
Source tapes/sources/init.tape

Type "git reset --hard HEAD~" Enter Sleep 0.25

Type "git switch -c feature1" Enter Sleep 0.25
Type "vim .data " Enter Sleep 0.25
Type "6Go" Sleep 0.25
Type "SEPARATOR #2.5" Enter
Type "CHANGE" Sleep 0.25
Escape
Type "ZZ" Sleep 0.25

Type "git add -p" Enter Sleep 0.25
Type "y" Sleep 0.25 Enter Sleep 0.25

Type "git commit" Sleep 0.25 Enter
Type "i" Sleep 0.25
Type "Add feature1" Sleep 0.25
Escape
Type "ZZ" Sleep 0.25

Type "git switch -c feature2" Enter Sleep 0.25
Type "vim .data" Enter Sleep 0.25
Type "14Go" Sleep 0.25
Type "SEPARATOR #5.5" Enter
Type "CHANGE" Sleep 0.25
Escape
Type "ZZ" Sleep 0.25

Type "git add -p" Enter Sleep 0.25
Type "y" Sleep 0.25 Enter Sleep 0.25
Source tapes/sources/git-commit-feature1.tape
Source tapes/sources/git-commit-feature2.tape

Type "git commit" Sleep 0.25 Enter
Type "i" Sleep 0.25
Type "Add feature2" Sleep 0.25
Escape
Type "ZZ" Sleep 0.25
Ctrl+L

Ctrl+L Sleep 0.25

Show

Sleep 1
Show Sleep 1

Type "git switch main" Enter Sleep 1
Type "git pull" Enter Sleep 5
Expand All @@ -78,7 +40,4 @@ Ctrl+L Sleep 0.25

Type "git show -p" Enter Sleep 3

Hide

Ctrl+D Sleep 0.25
Ctrl+D
Source tapes/sources/terminate.tape
16 changes: 16 additions & 0 deletions scripts/video/tapes/sources/git-commit-feature1.tape
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
Type "git switch -c feature1" Enter Sleep 1
Type "vim .data" Enter Sleep 1
Type "6Go" Sleep 0.25
Type "SEPARATOR #2.5" Enter
Type "CHANGE" Sleep 1
Escape
Type "ZZ" Sleep 1

Type "git add -p" Enter Sleep 3
Type "y" Sleep 1 Enter Sleep 1

Type "git commit" Sleep 1 Enter
Type "i" Sleep 0.25
Type "Add feature1" Sleep 1
Escape
Type "ZZ" Sleep 3
16 changes: 16 additions & 0 deletions scripts/video/tapes/sources/git-commit-feature2.tape
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
Type "git switch -c feature2" Enter Sleep 1
Type "vim .data" Enter Sleep 1
Type "14Go" Sleep 0.25
Type "SEPARATOR #5.5" Enter
Type "CHANGE" Sleep 1
Escape
Type "ZZ" Sleep 1

Type "git add -p" Enter Sleep 3
Type "y" Sleep 1 Enter Sleep 1

Type "git commit" Sleep 1 Enter
Type "i" Sleep 0.25
Type "Add feature2" Sleep 1
Escape
Type "ZZ" Sleep 3
9 changes: 9 additions & 0 deletions scripts/video/tapes/sources/init.tape
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
Set FontSize 18

Require docker

Hide

Type "docker-compose run demo" Enter Sleep 1

Ctrl+L
4 changes: 4 additions & 0 deletions scripts/video/tapes/sources/terminate.tape
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Hide

Ctrl+D
Ctrl+D

0 comments on commit 5f0517d

Please sign in to comment.