From 152ff29173a53d341a4df7475ec06aa184ca31ca Mon Sep 17 00:00:00 2001 From: Nuru Date: Fri, 10 May 2024 15:43:00 -0700 Subject: [PATCH] Fix font problem with vhs-action --- .github/workflows/vhs.yaml | 13 ++++++++++++- demo.tape | 15 +++++---------- 2 files changed, 17 insertions(+), 11 deletions(-) diff --git a/.github/workflows/vhs.yaml b/.github/workflows/vhs.yaml index 50da81f29..878ea7fbe 100644 --- a/.github/workflows/vhs.yaml +++ b/.github/workflows/vhs.yaml @@ -35,11 +35,22 @@ jobs: - name: "make all" run: make all + # We need to install the Hack Nerd Font for the demo + # but vhs-action will not install it for us due to issue 264 + - name: Install Hack Nerd Font + run: | + curl -sSLO https://github.com/ryanoasis/nerd-fonts/releases/download/v3.2.1/Hack.zip + unzip -d hack_nerd_font Hack.zip + mv hack_nerd_font/ /usr/local/share/fonts/ + fc-cache -fv || true + - uses: charmbracelet/vhs-action@v2 with: token: ${{ secrets.GITHUB_TOKEN }} path: demo.tape - install-fonts: true + # Cannot use `install-fonts`: https://github.com/charmbracelet/vhs-action/issues/264 + # install-fonts: true + install-fonts: false - uses: stefanzweifel/git-auto-commit-action@v5 id: auto-commit diff --git a/demo.tape b/demo.tape index ae924fa05..2bc7f4b6a 100644 --- a/demo.tape +++ b/demo.tape @@ -37,21 +37,16 @@ Type "geodesic" Enter Sleep 3s -Type "# It ships with common commands like `terraform`" Enter +Type "# It ships with common commands like `jq`" Enter Sleep 500ms -Type "terraform -help" Enter -Sleep 500ms +Type "jq" Enter +Sleep 3s -Type "# ...and the `aws` CLI =)" Enter +Type "# ...and `kubectl`" Enter Sleep 500ms -Type "aws help" Enter - -Sleep 3s - -Type "q" -Sleep 1s +Type "kubectl" Enter@3s Type "# That's all folks!" Enter Sleep 2s