diff options
author | Emily Trau <13267947+emilytrau@users.noreply.github.com> | 2024-04-06 07:49:21 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-06 07:49:21 +0800 |
commit | 1adad05124f931df1af1cbf1a0a102575825e932 (patch) | |
tree | 89f5bf0ef4b60861461ce64b7964f0ab67a09b31 | |
parent | d7d443c4ce766510ab94ba4f3e114ffa53075f03 (diff) | |
parent | dd4ff7bb3531d4ef3516233a453baa0c1282f206 (diff) |
Merge pull request #299107 from emilytrau/sloth-app
sloth-app: init at 3.2
-rw-r--r-- | pkgs/by-name/sl/sloth-app/package.nix | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/pkgs/by-name/sl/sloth-app/package.nix b/pkgs/by-name/sl/sloth-app/package.nix new file mode 100644 index 0000000000000..c2959589d0bae --- /dev/null +++ b/pkgs/by-name/sl/sloth-app/package.nix @@ -0,0 +1,40 @@ +{ lib +, stdenv +, fetchurl +, unzip +, makeBinaryWrapper +}: + +stdenv.mkDerivation (finalAttrs: { + pname = "sloth-app"; + version = "3.2"; + + src = fetchurl { + url = "https://github.com/sveinbjornt/Sloth/releases/download/${finalAttrs.version}/sloth-${finalAttrs.version}.zip"; + hash = "sha256-8/x8I769V8kGxstDuXXUaMtGvg03n2vhrKvmaltSISo="; + }; + + dontUnpack = true; + + nativeBuildInputs = [ unzip makeBinaryWrapper ]; + + installPhase = '' + runHook preInstall + + mkdir -p $out/Applications $out/bin + unzip -d $out/Applications $src + makeWrapper $out/Applications/Sloth.app/Contents/MacOS/Sloth $out/bin/Sloth + + runHook postInstall + ''; + + meta = { + description = "Mac app that shows all open files, directories, sockets, pipes and devices"; + homepage = "https://sveinbjorn.org/sloth"; + license = lib.licenses.bsd3; + mainProgram = "Sloth"; + maintainers = with lib.maintainers; [ emilytrau ]; + platforms = lib.platforms.darwin; + sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ]; + }; +}) |