aienos.com
Source of www.aienos.com, served from my own hardware
Brought by drakestapleton
aienos.com / om / hive-render / check.sh
| 1 | #!/bin/sh |
| 2 | # Shell is build/test coordination only, not the renderer implementation. |
| 3 | set -eu |
| 4 | cd "$(dirname "$0")" |
| 5 | omc=${OMEGA_OMC:-../hive-page/omc} |
| 6 | expected=734f0a39319fbfa930bcc62cb30dbf06d47d78e126372b74f5baf478e6126b61 |
| 7 | [ -x "$omc" ] || exit 2 |
| 8 | [ "$(sha256sum "$omc" | cut -d ' ' -f1)" = "$expected" ] || exit 3 |
| 9 | scratch=$(mktemp -d) |
| 10 | trap 'rm -rf "$scratch"' EXIT HUP INT TERM |
| 11 | nice -n 19 "$omc" < render.om > "$scratch/one" |
| 12 | nice -n 19 "$omc" < render.om > "$scratch/two" |
| 13 | cmp "$scratch/one" "$scratch/two" || exit 5 |
| 14 | [ -s "$scratch/one" ] || exit 6 |
| 15 | chmod +x "$scratch/one" |
| 16 | python3 test-render.py "$scratch/one" "$omc" "$scratch" |
| 17 | sha256sum render.om > render.om.sha256 |
| 18 | sha256sum "$scratch/one" | cut -d ' ' -f1 > hive-render.sha256 |
| 19 | cp "$scratch/one" hive-render |
| 20 | printf '%s\n' 'HIVE-RENDER PASS: deterministic compiler output, escaper differential, schema refusals, XSS text and tree checks' |