OXYGENHUB
◆ push-notes oxygen / .flow / riscv64-check.sh
998 B · Bourne Again Shell (bash) · executable · last changed riscv64 check: init before the identity, and cache the target directory 17 days ago source blame history raw
8d6cf1f2 Andy McCall ↶ 1
#!/bin/sh
2
# The native RISC-V check (oxygenflow#69): on narvi-1, a riscv64 board,
3
# build oxy natively and use it, so a release is known to work on real
4
# RISC-V hardware, not only to cross-compile for it (dist does that).
5
set -eu
6
uname -m
7
cargo build --release --locked -p oxy
8
oxy=/src/target/release/oxy
9
"$oxy" --version
10
# A repository's life in miniature: an identity, a signed change, a
11
# bookmark, a merge, and a full integrity check.
12
export OXY_HOME="$(mktemp -d)"
13
cd "$(mktemp -d)"
f5bd79d0 Andy McCall ↶ 14
"$oxy" --plain init
8d6cf1f2 Andy McCall ↶ 15
"$oxy" --plain identity create --name "narvi-1 check" --email [email protected]
16
"$oxy" --plain config --user core.sign change
17
echo one > a.txt
18
"$oxy" --plain commit -m "first"
19
"$oxy" --plain bookmark create side
20
"$oxy" --plain bookmark switch side
21
echo two > b.txt
22
"$oxy" --plain commit -m "second, on side"
23
"$oxy" --plain bookmark switch main
24
"$oxy" --plain merge side
25
"$oxy" --plain log
26
"$oxy" --plain verify
27
"$oxy" --plain fsck
28
test -f b.txt
29
echo "oxy works natively on $(uname -m)"