skeledance/plugin/contents/ui/cava-start.sh
ltadeu6 5876701a64
Add real-time CAVA audio visualizer for VU bars
CAVA runs in background via cava-start.sh, writing bar values to
/tmp/skeledance_bars. A new QML DataSource polls that file at 80ms
and calls updateBars() in JS. Falls back to rest state when not playing.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-07 09:35:35 -03:00

9 lines
286 B
Bash
Executable file

#!/usr/bin/env bash
# Kill any previous instance tied to this config
pkill -f "cava -p.*skeledance" 2>/dev/null
sleep 0.2
CONF="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)/cava.conf"
cava -p "$CONF" | while IFS= read -r line; do
printf '%s\n' "$line" > /tmp/skeledance_bars
done