feat(nix): add asciinema, vhs, and cargo-dist to dev shell
Add demo recording tools (asciinema, vhs) and release tooling (cargo-dist) to nativeBuildInputs. Include a cargo-dist wrapper so `cargo dist` works as a subcommand. Add scripts/record-demo.sh for consistent asciinema cast recording at 100x30. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
32
scripts/record-demo.sh
Executable file
32
scripts/record-demo.sh
Executable file
@ -0,0 +1,32 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
# Record asciinema demo casts at a consistent terminal size.
|
||||
# Usage: ./scripts/record-demo.sh [cast-name]
|
||||
# Without arguments, records all four standard casts.
|
||||
# With an argument, records just that one (import, pivot, drill, formulas).
|
||||
|
||||
CAST_DIR="docs/casts"
|
||||
COLS=100
|
||||
ROWS=30
|
||||
IDLE_CAP=2
|
||||
|
||||
mkdir -p "$CAST_DIR"
|
||||
|
||||
record() {
|
||||
local name="$1"
|
||||
local outfile="$CAST_DIR/${name}.cast"
|
||||
echo "Recording $name → $outfile (${COLS}x${ROWS}, idle cap ${IDLE_CAP}s)"
|
||||
echo "Press Ctrl-D or type 'exit' when done."
|
||||
COLUMNS=$COLS LINES=$ROWS asciinema rec -i "$IDLE_CAP" --cols "$COLS" --rows "$ROWS" "$outfile"
|
||||
echo "Saved $outfile"
|
||||
}
|
||||
|
||||
if [ $# -gt 0 ]; then
|
||||
record "$1"
|
||||
else
|
||||
for name in import pivot drill formulas; do
|
||||
record "$name"
|
||||
echo ""
|
||||
done
|
||||
fi
|
||||
Reference in New Issue
Block a user