bin.nix (1002B)
1 { lib, stdenv, fetchurl, undmg, cudatext }: 2 3 stdenv.mkDerivation (finalAttrs: { 4 pname = "cudatext-bin"; 5 version = "1.195.0.5"; 6 7 src = { 8 "aarch64-darwin" = fetchurl { 9 url = "mirror://sourceforge/cudatext/cudatext-macos-cocoa-aarch64-${finalAttrs.version}.dmg"; 10 hash = "sha256-GMaqPnSEjzENcNpFi7YF5qENyk/sDEHCU/Xk/hYQtrQ="; 11 }; 12 "x86_64-darwin" = fetchurl { 13 url = "mirror://sourceforge/cudatext/cudatext-macos-cocoa-amd64-${finalAttrs.version}.dmg"; 14 hash = "sha256-pNwpTACaK/tpA2bcZa0QyAndbT/r2aLomfynNibJcH4="; 15 }; 16 }.${stdenv.hostPlatform.system}; 17 18 nativeBuildInputs = [ undmg ]; 19 20 sourceRoot = "."; 21 22 installPhase = '' 23 runHook preInstall 24 25 mkdir -p $out/Applications 26 cp -R *.app $out/Applications 27 28 runHook postInstall 29 ''; 30 31 meta = with lib; { 32 inherit (cudatext.meta) description homepage changelog license; 33 platforms = [ "aarch64-darwin" "x86_64-darwin" ]; 34 maintainers = [ maintainers.sikmir ]; 35 skip.ci = true; 36 }; 37 })