linux_xanmod: 5.11.14 -> 5.11.15
[NixPkgs.git] / pkgs / tools / networking / ngrok-2 / update.sh
blob7908a1524e594e9364142f4237080781fb77a90f
1 #!/usr/bin/env nix-shell
2 #!nix-shell -p httpie
3 #!nix-shell -p jq
4 #!nix-shell -i bash
6 set -eu -o pipefail
8 get_download_info() {
9 http --body \
10 https://update.equinox.io/check \
11 'Accept:application/json; q=1; version=1; charset=utf-8' \
12 'Content-Type:application/json; charset=utf-8' \
13 app_id=app_goVRodbMVm \
14 channel=stable \
15 os=$1 \
16 goarm= \
17 arch=$2 \
18 | jq --arg sys "$1-$2" '{
19 sys: $sys,
20 url: .download_url,
21 sha256: .checksum,
22 version: .release.version
27 get_download_info linux 386
28 get_download_info linux amd64
29 get_download_info linux arm
30 get_download_info linux arm64
31 get_download_info darwin amd64
32 ) | jq --slurp 'map ({ (.sys): . }) | add' \
33 > pkgs/tools/networking/ngrok-2/versions.json