the face stays quiet when the rig is not staged; add stage-face.sh
This commit is contained in:
parent
bb81781007
commit
8e3120c5a0
2 changed files with 33 additions and 0 deletions
17
tools/stage-face.sh
Executable file
17
tools/stage-face.sh
Executable file
|
|
@ -0,0 +1,17 @@
|
|||
#!/usr/bin/env bash
|
||||
# Put the Live2D rig where the face host expects it.
|
||||
#
|
||||
# The rig is licensed assets and stays out of every repo (TASK-59) — so it is
|
||||
# copied onto a device, never cloned with the source. Without this the host has
|
||||
# an index.html referring to files that are not there, which is the "missing
|
||||
# assets/face" every fresh checkout sees.
|
||||
set -euo pipefail
|
||||
SRC="${1:-$HOME/Downloads/blog/Live2dHistoire/live2d}"
|
||||
DEST="${FACE_DIR:-$HOME/.souveraine/face}"
|
||||
HERE="$(cd "$(dirname "$0")/.." && pwd)"
|
||||
|
||||
[ -d "$SRC" ] || { echo "no rig at $SRC — pass its path as \$1" >&2; exit 1; }
|
||||
mkdir -p "$DEST"
|
||||
cp -r "$SRC" "$DEST/"
|
||||
cp "$HERE/assets/face/index.html" "$DEST/index.html"
|
||||
echo "staged $(du -sh "$DEST" | cut -f1) at $DEST"
|
||||
Loading…
Reference in a new issue