Skip to content

Commit

Permalink
Add a demo for stack restack
Browse files Browse the repository at this point in the history
  • Loading branch information
draftcode committed Aug 21, 2024
1 parent 77bdc9e commit 9b423ca
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 2 deletions.
Binary file added demos/stack_restack/stack_restack.mp4
Binary file not shown.
40 changes: 40 additions & 0 deletions demos/stack_restack/stack_restack.tape
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
Output stack_restack.mp4

Set FontFamily "Cascadia Mono NF"

Set Shell "bash"
Set FontSize 20
Set Width 1200
Set Height 1200

Hide
Type '. ../test_utils.sh' Enter
Type 'new_temp_repo' Enter

Type 'av stack branch stack-1' Enter
Type 'create_commit "my-file" "1a" "Commit 1a"' Enter

Type 'av stack branch stack-2' Enter
Type 'create_commit "my-file" "2a" "Commit 2a"' Enter

Type 'av stack branch stack-3' Enter
Type 'create_commit "my-file" "3a" "Commit 3a"' Enter

Type 'git switch stack-1' Enter
Type 'clear' Enter
Show

Type 'av stack tree' Enter
Sleep 2

Type 'git commit --amend -m "Commit 1a (amended)"' Enter
Sleep 2

Type 'git --no-pager log --graph --all' Enter
Sleep 2

Type 'av stack restack' Enter
Sleep 3

Type 'git --no-pager log --graph --all' Enter
Sleep 3
2 changes: 0 additions & 2 deletions demos/test_utils.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
#!/bin/bash

set -ex

function new_temp_repo {
cd "$(dirname -- "${BASH_SOURCE[0]}")"
go build ../cmd/av
Expand Down

0 comments on commit 9b423ca

Please sign in to comment.