lol

kent: add updateScript

kyehn ecb4b982 8c5f8032

+8
+8
pkgs/by-name/ke/kent/package.nix
··· 12 12 bash, 13 13 fetchFromGitHub, 14 14 which, 15 + writeShellScript, 16 + jq, 17 + nix-update, 15 18 }: 16 19 stdenv.mkDerivation rec { 17 20 pname = "kent"; ··· 83 86 cp -r $HOME/inc/* $out/inc/ 84 87 85 88 runHook postInstall 89 + ''; 90 + 91 + passthru.updateScript = writeShellScript "update-kent" '' 92 + latestVersion=$(curl ''${GITHUB_TOKEN:+-u ":$GITHUB_TOKEN"} --fail --silent https://api.github.com/repos/ucscGenomeBrowser/kent/releases/latest | ${lib.getExe jq} --raw-output .tag_name | grep -oP '(?<=v)\d+') 93 + ${lib.getExe nix-update} kent --version $latestVersion 86 94 ''; 87 95 88 96 meta = {