biglybt: 3.5.0.0 -> 3.6.0.0
[NixPkgs.git] / pkgs / servers / jackett / updater.sh
blob1714565edd4917cefa0f6c2036ee35f2a3592ded
1 #!/usr/bin/env nix-shell
2 #!nix-shell -I nixpkgs=./. -i bash -p curl jq common-updater-scripts
3 set -eo pipefail
4 cd "$(dirname "${BASH_SOURCE[0]}")"
6 new_version="$(curl -s "https://api.github.com/repos/jackett/jackett/releases?per_page=1" | jq -r '.[0].name')"
7 old_version="$(sed -nE 's/\s*version = "(.*)".*/\1/p' ./default.nix)"
9 if [[ "$new_version" == "$old_version" ]]; then
10 echo "Already up to date!"
11 exit 0
14 cd ../../..
15 update-source-version jackett "${new_version//v}"
16 $(nix-build -A jackett.fetch-deps --no-out-link)