nixpkgs/pkgs/development/tools/replay-io/update.sh
Lenz Weber-Tronic f51cb36f2c
replay-io: init at 20220516-372662e7c79d-a9c63f38ea9b, replay-node-cli: init at 20220506-096c12cb47eb-a1d05f422dff (#166813)
* replay-io: init at 20220401-29dd94a55ca4

* init replay-node-cli at 20220404-dfd3123c41e3-4e44aca4c7ee

* replay-io: init at 20220422-1d46e798ffbf-3eecf49b757b, replay-node-cli: init at 0.1.7-20220422-a26b4562ebf7-3eecf49b757b

* fixup

* apply feedback

* replay-io: init at 20220516-372662e7c79d-a9c63f38ea9b, replay-node-cli: init at 20220506-096c12cb47eb-a1d05f422dff

* use `stripRoot: false`
2022-05-31 14:36:05 +02:00

32 lines
994 B
Bash
Executable file

#!/usr/bin/env nix-shell
#!nix-shell -i bash -p curl jq gnused
set -euo pipefail
# e.g. linux-gecko-20220331-59d0a686993f-ffd8d6280276
BUILD_ID=$(curl https://static.replay.io/downloads/linux-replay.json | jq .buildId -r)
REVISION=$(echo $BUILD_ID | sed 's/^.*-//')
NODE_BUILD_ID=$(curl https://static.replay.io/downloads/linux-replay-node.json | jq .buildId -r)
REPLAY_DL=https://static.replay.io/downloads/${BUILD_ID}.tar.bz2
LIB_DL=https://static.replay.io/downloads/linux-recordreplay-${REVISION}.tgz
NODE_DL=https://static.replay.io/downloads/${NODE_BUILD_ID}
cat >"${BASH_SOURCE%/*}/meta.json" <<EOF
{
"replay": {
"url": "${REPLAY_DL}",
"sha256": "$(nix-prefetch-url --type sha256 "${REPLAY_DL}")"
},
"recordreplay": {
"url": "${LIB_DL}",
"sha256": "$(nix-prefetch-url --type sha256 --unpack "${LIB_DL}")",
"stripRoot": false
},
"replay-node": {
"url": "${NODE_DL}",
"sha256": "$(nix-prefetch-url --type sha256 "${NODE_DL}")"
}
}
EOF