From 9c4f581af46df2bacab3bcd54b2b84a0e1329f5f Mon Sep 17 00:00:00 2001 From: Andrei Pampu Date: Fri, 18 Feb 2022 00:44:54 +0200 Subject: [PATCH] radarr: 3.2.2.5080 -> 4.0.4.5922 --- pkgs/servers/radarr/default.nix | 8 ++++---- pkgs/servers/radarr/update.sh | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/pkgs/servers/radarr/default.nix b/pkgs/servers/radarr/default.nix index acb3ba82a4ac..fe3016379978 100644 --- a/pkgs/servers/radarr/default.nix +++ b/pkgs/servers/radarr/default.nix @@ -9,14 +9,14 @@ let }."${stdenv.hostPlatform.system}" or (throw "Unsupported system: ${stdenv.hostPlatform.system}"); hash = { - x64-linux_hash = "sha256-IwD7PFRz6mjEjUTbpqItorvFMB/hcMcRhHG8XQHv0iM="; - arm64-linux_hash = "sha256-9Ou08PI3HNQO6Da76ZMkzx1QlU+oaq9Tr+vqPT05xnw="; - x64-osx_hash = "sha256-Nfm9vWB+ii2ZST6I4I8Y2PuG2a1qY7rbki57y88Ft8A="; + x64-linux_hash = "sha256-2DZUQ11sAsIbI3hkU+6Hj+xHz3EbsTelisUCOlRBvvQ="; + arm64-linux_hash = "sha256-j5gUC50NfvF2/W/aYgCiMoW1jF9F30L7pnVaFfX1Fwk="; + x64-osx_hash = "sha256-iOaOzisG54+nstPNNUXOYwhEaM1Uh4wHPISVtEf8vTQ="; }."${arch}-${os}_hash"; in stdenv.mkDerivation rec { pname = "radarr"; - version = "3.2.2.5080"; + version = "4.0.4.5922"; src = fetchurl { url = "https://github.com/Radarr/Radarr/releases/download/v${version}/Radarr.master.${version}.${os}-core-${arch}.tar.gz"; diff --git a/pkgs/servers/radarr/update.sh b/pkgs/servers/radarr/update.sh index 240689eb4537..ce64b6df429b 100755 --- a/pkgs/servers/radarr/update.sh +++ b/pkgs/servers/radarr/update.sh @@ -15,7 +15,7 @@ updateHash() url="https://github.com/Radarr/Radarr/releases/download/v$version/Radarr.master.$version.$os-core-$arch.tar.gz" hash=$(nix-prefetch-url --type sha256 $url) - sriHash="$(nix to-sri --type sha256 $hash)" + sriHash="$(nix hash to-sri --type sha256 $hash)" sed -i "s|$hashKey = \"[a-zA-Z0-9\/+-=]*\";|$hashKey = \"$sriHash\";|g" "$dirname/default.nix" } @@ -25,7 +25,7 @@ updateVersion() sed -i "s/version = \"[0-9.]*\";/version = \"$1\";/g" "$dirname/default.nix" } -currentVersion=$(cd $dirname && nix eval --raw '(with import ../../.. {}; radarr.version)') +currentVersion=$(cd $dirname && nix eval --raw -f ../../.. radarr.version) latestTag=$(curl https://api.github.com/repos/Radarr/Radarr/releases/latest | jq -r ".tag_name") latestVersion="$(expr $latestTag : 'v\(.*\)')"