From 71e370e534b5de281f5e5dbd758a9b5c0ac18f6b Mon Sep 17 00:00:00 2001 From: Jonathan Ringer Date: Tue, 20 Jul 2021 10:23:48 -0700 Subject: [PATCH] mill: 0.9.6 -> 0.9.9 Use the `${version}-assembly` artifact, which avoids having to download it using the release script (cherry picked from commit 74090eb68a2fd8e0a6ef0000f36a784ed2d27194) --- .../tools/build-managers/mill/default.nix | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/pkgs/development/tools/build-managers/mill/default.nix b/pkgs/development/tools/build-managers/mill/default.nix index 4fbd0365af9..27a21619c1d 100644 --- a/pkgs/development/tools/build-managers/mill/default.nix +++ b/pkgs/development/tools/build-managers/mill/default.nix @@ -2,11 +2,11 @@ stdenv.mkDerivation rec { pname = "mill"; - version = "0.9.6"; + version = "0.9.9"; src = fetchurl { - url = "https://github.com/com-lihaoyi/mill/releases/download/${version}/${version}"; - sha256 = "sha256-cAhcTmSPkV5z5ryuCNrpxy9/1iWvvminiVYul9c/DwM="; + url = "https://github.com/com-lihaoyi/mill/releases/download/${version}/${version}-assembly"; + sha256 = "sha256-HIT7bxMEz7jpSsYvohN9+zYuyCf/ARE7hd48YMTo9/4="; }; nativeBuildInputs = [ makeWrapper ]; @@ -15,6 +15,9 @@ stdenv.mkDerivation rec { dontConfigure = true; dontBuild = true; + # this is mostly downloading a pre-built artifact + preferLocal = true; + installPhase = '' runHook preInstall install -Dm555 "$src" "$out/bin/.mill-wrapped" @@ -25,6 +28,13 @@ stdenv.mkDerivation rec { runHook postInstall ''; + doInstallCheck = true; + # The default release is a script which will do an impure download + # just ensure that the application can run without network + installCheckPhase = '' + $out/bin/mill --help > /dev/null + ''; + meta = with lib; { homepage = "https://www.lihaoyi.com/mill"; license = licenses.mit;