# `nix run .#hyperhive-the-movie` — gource visualisation of the git # history of the repo it is run from. `-- --record` renders # gource-hyperhive.mp4 in the cwd instead of opening a window. { lib, writeShellApplication, gource, ffmpeg, xvfb-run, librsvg, curl, git, coreutils, gnugrep, logo, }: writeShellApplication { name = "hyperhive-the-movie"; runtimeInputs = [ gource ffmpeg xvfb-run librsvg curl git coreutils gnugrep ]; text = '' record=false [[ "''${1:-}" == "--record" ]] && record=true cd "$(git rev-parse --show-toplevel)" # Per-agent avatars from the local forge (same icons the dashboard # uses), rasterised because --user-image-dir needs png. Cached. # müde is the human operator: no forge icon. avatar_dir="''${XDG_CACHE_HOME:-$HOME/.cache}/hyperhive-the-movie/avatars" mkdir -p "$avatar_dir" while IFS= read -r author; do [[ "$author" == "müde" || -f "$avatar_dir/$author.png" ]] && continue svg="$avatar_dir/$author.svg" curl -sSf "http://localhost/agent/$author/icon" -o "$svg" 2>/dev/null || rm -f "$svg" # unknown agents get a 200 html fallback page, not a 404 if [[ -f "$svg" ]]; then if head -c 200 "$svg" | grep -qi '