Skip to content

generate-terminal-gifs #31

generate-terminal-gifs

generate-terminal-gifs #31

name: generate-terminal-gifs
on:
workflow_dispatch:
permissions:
contents: write
pull-requests: write
jobs:
generate-gifs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.x'
- name: Setup Go
uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00
with:
go-version: '1.25.1'
- name: Install VHS dependencies
run: |
sudo apt-get update
sudo apt-get install -y ffmpeg ttyd
go install github.com/charmbracelet/vhs@latest
- name: Install JetBrainsMono Nerd Font
run: |
mkdir -p ~/.local/share/fonts/JetBrainsMono
curl -fLo /tmp/JetBrainsMono.zip \
https://github.com/ryanoasis/nerd-fonts/releases/latest/download/JetBrainsMono.zip
unzip -o /tmp/JetBrainsMono.zip -d ~/.local/share/fonts/JetBrainsMono
fc-cache -fv
- name: Set up virtual environment
run: |
python3 -m venv .venv
.venv/bin/pip install --upgrade pip
.venv/bin/pip install -e .
- name: Generate GIFs
run: bash scripts/generate-gifs.sh
- name: Create Pull Request
uses: peter-evans/create-pull-request@v8
with:
commit-message: 'chore: update generated VHS GIFs'
branch: automation/update-vhs-gifs-${{ github.run_id }}
title: '[chore] update generated VHS GIFs'
body: |
This PR updates all generated VHS GIF files.
Triggered by workflow run [${{ github.run_id }}](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}).
base: main
labels: automation