Skip to content

Worktrunk is a CLI for Git worktree management, designed for parallel AI agent workflows

Move demo GIF to external assets repo to reduce repo size

Maximilian Roos891a2b320521
diff --git a/.github/workflows/build-docs.yaml b/.github/workflows/build-docs.yaml
index d335c11a6..a2ad82579 100644
--- a/.github/workflows/build-docs.yaml
+++ b/.github/workflows/build-docs.yaml
@@ -15,6 +15,12 @@ jobs:
with:
+ - name: Fetch demo assets
+ run: |
+ mkdir -p docs/static/assets
+ curl -fsSL -o docs/static/assets/wt-demo.gif \
+ https://raw.githubusercontent.com/max-sixty/worktrunk-assets/main/demos/wt-demo.gif
+
- name: πŸ•·οΈ Build docs
run: zola build
working-directory: docs
diff --git a/.gitignore b/.gitignore
index 20e041463..bfd99c672 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,6 +1,6 @@
/target
-dev/wt-demo/out/*
-!dev/wt-demo/out/wt-demo.gif
+dev/wt-demo/out/
+docs/static/assets/
# Lychee link checker cache
.lycheecache
diff --git a/README.md b/README.md
index a762ab872..f30bf3ae6 100644
--- a/README.md
+++ b/README.md
@@ -42,7 +42,7 @@ I'd recommend:
## Demo
-![Worktrunk Demo](dev/wt-demo/out/wt-demo.gif)
+![Worktrunk Demo](https://cdn.jsdelivr.net/gh/max-sixty/worktrunk-assets@main/demos/wt-demo.gif)
## Quick Start
diff --git a/dev/wt-demo-build b/dev/wt-demo-build
index e85467df7..9b6e69341 100755
--- a/dev/wt-demo-build
+++ b/dev/wt-demo-build
@@ -349,9 +349,14 @@ def main():
# Cleanup
TAPE_RENDERED.unlink(missing_ok=True)
+ # Copy to docs for local preview
+ docs_assets = REPO_ROOT / "docs" / "static" / "assets"
+ docs_assets.mkdir(parents=True, exist_ok=True)
+ shutil.copy(OUTPUT_GIF, docs_assets / "wt-demo.gif")
+
print(f"GIF saved to {OUTPUT_GIF}")
+ print(f"Copied to {docs_assets / 'wt-demo.gif'}")
print(f"Text log saved to {OUT_DIR / 'run.txt'}")
- print(f"Log: {LOG}")
if __name__ == "__main__":
diff --git a/dev/wt-demo/CLAUDE.md b/dev/wt-demo/CLAUDE.md
index ba14d20f8..afda41f6d 100644
--- a/dev/wt-demo/CLAUDE.md
+++ b/dev/wt-demo/CLAUDE.md
@@ -7,12 +7,83 @@
```
Creates:
-- `dev/wt-demo/out/wt-demo.gif` - Animated demo (~1.9 MB)
+- `dev/wt-demo/out/wt-demo.gif` - Animated demo (~2 MB)
- `dev/wt-demo/out/run.txt` - Text transcript
- `dev/wt-demo/out/record.log` - Recording log
The script creates a fresh temp repo under `dev/wt-demo/out/.demo-*/`, seeds 4 worktrees + 2 extra branches, shows `wt list`, creates a worktree, edits a file, merges with `wt merge`, then shows `wt list --branches --full`.
+## Publishing
+
+Demo GIFs are hosted in [worktrunk-assets](https://github.com/max-sixty/worktrunk-assets) to avoid bloating the main repo.
+
+**Build β†’ Preview β†’ Publish:**
+
+```bash
+# 1. Build the demo (auto-copies to docs/static/assets/ for local preview)
+./dev/wt-demo-build
+
+# 2. Preview inline (zola serve should be running)
+# View at http://127.0.0.1:1111/quickstart/
+
+# 3. Publish when satisfied
+./scripts/publish-assets
+```
+
+The script auto-clones the assets repo if needed.
+
+### How the Paths Connect
+
+**File locations:**
+```
+worktrunk/
+β”œβ”€β”€ dev/wt-demo/out/wt-demo.gif # Build output (gitignored)
+β”œβ”€β”€ docs/static/assets/wt-demo.gif # Local preview (gitignored)
+└── docs/content/quickstart.md # References: /assets/wt-demo.gif
+
+../worktrunk-assets/
+└── demos/wt-demo.gif # Published asset
+```
+
+**Path 1: Local Preview**
+```
+./dev/wt-demo-build
+ β†’ creates dev/wt-demo/out/wt-demo.gif
+ β†’ copies to docs/static/assets/wt-demo.gif
+
+zola serve (in docs/)
+ β†’ serves docs/static/assets/* at /assets/*
+ β†’ quickstart.md ![](/assets/wt-demo.gif) resolves to local file
+```
+
+**Path 2: Publish**
+```
+./scripts/publish-assets
+ β†’ copies dev/wt-demo/out/wt-demo.gif
+ β†’ to ../worktrunk-assets/demos/wt-demo.gif
+ β†’ pushes to GitHub
+```
+
+**Path 3: CI Build** (`.github/workflows/build-docs.yaml`)
+```
+curl https://raw.githubusercontent.com/max-sixty/worktrunk-assets/main/demos/wt-demo.gif
+ β†’ saves to docs/static/assets/wt-demo.gif
+
+zola build
+ β†’ copies docs/static/assets/* to docs/public/assets/*
+ β†’ quickstart.md ![](/assets/wt-demo.gif) resolves correctly
+```
+
+**Path 4: README on GitHub.com**
+```
+README.md references:
+ https://cdn.jsdelivr.net/gh/max-sixty/worktrunk-assets@main/demos/wt-demo.gif
+ β†’ jsDelivr fetches from worktrunk-assets repo
+ β†’ GitHub renders the image inline
+```
+
+**Key invariant:** All paths end with the GIF at `/assets/wt-demo.gif` (local, CI) or CDN (README).
+
## Viewing Results
**Do NOT use `open` on the GIF** - that's for the user to do manually.
diff --git a/dev/wt-demo/out/wt-demo.gif b/dev/wt-demo/out/wt-demo.gif
deleted file mode 100644
index 47039f660..000000000
Binary files a/dev/wt-demo/out/wt-demo.gif and /dev/null differ
diff --git a/docs/CLAUDE.md b/docs/CLAUDE.md
index ffa50f7e2..1cec47885 100644
--- a/docs/CLAUDE.md
+++ b/docs/CLAUDE.md
@@ -1,5 +1,17 @@
# Docs Site
+## Demo GIF Workflow
+
+See `dev/wt-demo/CLAUDE.md` for the full workflow. Quick reference:
+
+```bash
+./dev/wt-demo-build # Build (auto-copies to docs/static/assets/)
+# View at http://127.0.0.1:1111/quickstart/
+./scripts/publish-assets # Publish to assets repo
+```
+
+---
+
This is an initial scaffolding of the documentation site. The content was auto-generated from the main README and has not been reviewed for accuracy.
**Do not trust any content here.** Before this is production-ready:
diff --git a/docs/content/quickstart.md b/docs/content/quickstart.md
index f54a9db74..afabe7582 100644
--- a/docs/content/quickstart.md
+++ b/docs/content/quickstart.md
@@ -5,7 +5,7 @@ weight = 1
Worktrunk is a CLI for Git worktree management, designed for parallel AI agent workflows. Git worktrees give each agent an isolated branch and directory; Worktrunk adds branch-based navigation, unified status, and lifecycle hooks. It makes spinning up a new AI "developer" for a task feel as routine as `git switch`.
-![Worktrunk Demo](/wt-demo.gif)
+![Worktrunk Demo](/assets/wt-demo.gif)
## Install
diff --git a/scripts/publish-assets b/scripts/publish-assets
new file mode 100755
index 000000000..3f8cde929
--- /dev/null
+++ b/scripts/publish-assets
@@ -0,0 +1,58 @@
+#!/bin/bash
+# Publish demo assets to the worktrunk-assets repo
+set -euo pipefail
+
+SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
+REPO_ROOT="$(dirname "$SCRIPT_DIR")"
+DEMO_OUT="$REPO_ROOT/dev/wt-demo/out"
+ASSETS_REPO="$REPO_ROOT/../worktrunk-assets"
+
+# Clone assets repo if needed
+if [[ ! -d "$ASSETS_REPO/.git" ]]; then
+ if ! command -v gh &>/dev/null; then
+ echo "Error: gh CLI required. Install from https://cli.github.com/"
+ exit 1
+ fi
+ echo "Cloning assets repo..."
+ if ! gh repo clone max-sixty/worktrunk-assets "$ASSETS_REPO"; then
+ echo "Failed to clone assets repo"
+ exit 1
+ fi
+fi
+
+# Check for demo output
+if [[ ! -f "$DEMO_OUT/wt-demo.gif" ]]; then
+ echo "Demo GIF not found at $DEMO_OUT/wt-demo.gif"
+ echo "Build it first: ./dev/wt-demo-build"
+ exit 1
+fi
+
+# Update assets repo
+cd "$ASSETS_REPO"
+if ! git pull --ff-only; then
+ echo "Failed to update assets repo. Check for uncommitted changes."
+ exit 1
+fi
+
+# Copy new assets
+echo "Copying assets..."
+cp "$DEMO_OUT/wt-demo.gif" "$ASSETS_REPO/demos/"
+
+# Check for changes
+if git diff --quiet demos/; then
+ echo "No changes to publish"
+ exit 0
+fi
+
+# Show what changed
+echo "Changes:"
+git diff --stat demos/
+
+# Commit and push
+git add demos/
+git commit -m "Update demo assets"
+git push
+
+echo ""
+echo "Published: https://raw.githubusercontent.com/max-sixty/worktrunk-assets/main/demos/wt-demo.gif"
+echo "CDN (~1 min to update): https://cdn.jsdelivr.net/gh/max-sixty/worktrunk-assets@main/demos/wt-demo.gif"