2023-12-22 14:15:59 +00:00
|
|
|
{ stdenv, fetchurl, unzip, lib }:
|
|
|
|
|
|
|
|
let
|
|
|
|
inherit (lib) getAttr;
|
|
|
|
in
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "xcbeautify";
|
2024-03-22 14:21:44 +00:00
|
|
|
version = "1.4.0";
|
2023-12-22 14:15:59 +00:00
|
|
|
arch = if stdenv.hostPlatform.isAarch64 then "arm64" else "x86_64";
|
|
|
|
|
2024-03-22 14:21:44 +00:00
|
|
|
|
2023-12-22 14:15:59 +00:00
|
|
|
src = fetchurl {
|
2024-03-22 14:21:44 +00:00
|
|
|
url = "https://github.com/cpisciotta/xcbeautify/releases/download/${version}/xcbeautify-${version}-${arch}-apple-macosx.zip";
|
2023-12-22 14:15:59 +00:00
|
|
|
sha256 = getAttr arch {
|
2024-03-22 14:21:44 +00:00
|
|
|
arm64 = "sha256-4b4mXT5IfNOS8iOrZASDhTrmOehG4mePcoiKxR+IdZk=";
|
|
|
|
x86_64 = "sha256-adEfAK7n3Q/Yd1deyJx7htX7hZaGDztEeBv4z2A0wzg=";
|
2023-12-22 14:15:59 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ unzip ];
|
|
|
|
|
|
|
|
unpackPhase = ''
|
|
|
|
unzip $src
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
install -D xcbeautify $out/bin/xcbeautify
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A little beautifier tool for xcodebuild";
|
2024-03-22 14:21:44 +00:00
|
|
|
homepage = "https://github.com/cpisciotta/xcbeautify";
|
2023-12-22 14:15:59 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
platforms = platforms.darwin;
|
|
|
|
};
|
|
|
|
}
|