#!/bin/sh # Rebuild the committed example previews from their content.json. set -eu here=$(cd "$(dirname "$0")/.." && pwd) for name in local-workshop remote-gathering; do tmp=$(mktemp -d) node "$here/reference/build.mjs" "$here/examples/$name/content.json" "$tmp" >/dev/null rm -rf "$here/examples/$name/preview" cp -R "$tmp/public" "$here/examples/$name/preview" rm -rf "$tmp" done