-
-
Notifications
You must be signed in to change notification settings - Fork 229
/
Copy pathdeploy-libc-test
executable file
·33 lines (27 loc) · 971 Bytes
/
deploy-libc-test
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/sh
set -ex
# e.g. deploy-libc-test regression/scanf-bytes-consumed
T=/mnt/videos/website/justine.lol/libc-test/bin
L=/home/jart/vendor/libc-test/src
V=2
mkdir -p $T/$V
for f; do
if [ ! -f $L/$f.exe ]; then
echo "not found: $L/$f" >&2
exit 1
fi
mkdir -p $T/$V/${f%/*}
mkdir -p ~/blink/third_party/libc-test/bin/$V/${f%/*}
cp $L/$f.exe $T/$V/$f.elf
rm -f $T/$V/$f.elf.gz
gzip $T/$V/$f.elf
sha256sum -b $T/$V/$f.elf.gz >$T/$V/$f.elf.gz.sha256
mkdir -p ~/blink/third_party/libc-test/bin/$V
cp $T/$V/$f.elf.gz.sha256 ~/blink/third_party/libc-test/bin/$V/$f.elf.gz.sha256
sed -i -e 's!/mnt/videos/website/justine.lol/libc-test/bin!third_party/libc-test/bin!' \
~/blink/third_party/libc-test/bin/$V/$f.elf.gz.sha256
ssh debian gsutil -m -h Cache-Control:public,max-age=31536000 cp -r -a public-read \
/mnt/videos/website/justine.lol/libc-test/bin/$V/$f.elf.gz \
gs://justine/libc-test/bin/$V/$f.elf.gz
done
syncweb