Watch
1
0
Fork
You've already forked souveraine
0

the face stays quiet when the rig is not staged; add stage-face.sh

This commit is contained in:
Fimeg 2026-08-05 20:11:31 -04:00
commit 8e3120c5a0
2 changed files with 33 additions and 0 deletions

View file

@ -50,9 +50,25 @@ Singleton {
+ "These are the postures the presence system already uses. "
+ "Use them sparingly, where the shift is real."
// The rig is not in the repo and never will be it is licensed assets on
// Casey's own device (TASK-59). So its absence is the ordinary state of any
// machine that has not staged it, and it must read as "not set up here"
// rather than as a broken face.
property bool rigPresent: rigProbe.exists
FileView {
id: rigProbe
path: root.rigDir + "/index.html"
preload: true
}
function join() {
if (root.joined)
return;
if (!root.rigPresent) {
console.log("[face] no rig at " + root.rigDir
+ " — stage it with tools/stage-face.sh; not joining");
return;
}
host.running = true;
root.joined = true;
}

17
tools/stage-face.sh Executable file
View 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"