Merge pull request #237556 from ereslibre/unison-use-finalAttrs-pattern

unison: use finalAttrs pattern
This commit is contained in:
Weijia Wang 2023-06-13 18:23:22 +03:00 committed by GitHub
commit 8594a8e1e9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,19 +4,19 @@
, less
}:
stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
pname = "unison-code-manager";
milestone_id = "M4i";
version = "1.0.${milestone_id}-alpha";
version = "1.0.${finalAttrs.milestone_id}-alpha";
src = if (stdenv.isDarwin) then
fetchurl {
url = "https://github.com/unisonweb/unison/releases/download/release/${milestone_id}/ucm-macos.tar.gz";
url = "https://github.com/unisonweb/unison/releases/download/release/${finalAttrs.milestone_id}/ucm-macos.tar.gz";
hash = "sha256-1Qp1SB5rCsVimZzRo1NOX8HBoMEGlIycJPm3zGTUuOw=";
}
else
fetchurl {
url = "https://github.com/unisonweb/unison/releases/download/release/${milestone_id}/ucm-linux.tar.gz";
url = "https://github.com/unisonweb/unison/releases/download/release/${finalAttrs.milestone_id}/ucm-linux.tar.gz";
hash = "sha256-Qx8vO/Vaz0VdCGXwIwRQIuMlp44hxCroQ7m7Y+m7aXk=";
};
@ -45,4 +45,4 @@ stdenv.mkDerivation rec {
platforms = [ "x86_64-darwin" "x86_64-linux" "aarch64-darwin" ];
mainProgram = "ucm";
};
}
})