about summary refs log tree commit diff
path: root/pkgs/by-name
diff options
context:
space:
mode:
authorRick van Schijndel <Mindavi@users.noreply.github.com>2023-12-09 10:58:04 +0100
committerGitHub <noreply@github.com>2023-12-09 10:58:04 +0100
commit1f3c762a95f284c0173948b569c3c047acc289f9 (patch)
treec3f8fa14c2767c9cd08e1bd90a54ed3173f3bc8d /pkgs/by-name
parent5eb361eeb014f6b0dc2a4cbca34b5317560e3a0d (diff)
parentfb95efda8e00dd4307b3caeffce969d956eabee4 (diff)
downloadnixlib-1f3c762a95f284c0173948b569c3c047acc289f9.tar
nixlib-1f3c762a95f284c0173948b569c3c047acc289f9.tar.gz
nixlib-1f3c762a95f284c0173948b569c3c047acc289f9.tar.bz2
nixlib-1f3c762a95f284c0173948b569c3c047acc289f9.tar.lz
nixlib-1f3c762a95f284c0173948b569c3c047acc289f9.tar.xz
nixlib-1f3c762a95f284c0173948b569c3c047acc289f9.tar.zst
nixlib-1f3c762a95f284c0173948b569c3c047acc289f9.zip
Merge pull request #271613 from Schweber/master
hdrop: init at 0.2.4
Diffstat (limited to 'pkgs/by-name')
-rwxr-xr-xpkgs/by-name/hd/hdrop/package.nix52
1 files changed, 52 insertions, 0 deletions
diff --git a/pkgs/by-name/hd/hdrop/package.nix b/pkgs/by-name/hd/hdrop/package.nix
new file mode 100755
index 000000000000..940cdf8f66b3
--- /dev/null
+++ b/pkgs/by-name/hd/hdrop/package.nix
@@ -0,0 +1,52 @@
+{ lib
+, stdenvNoCC
+, fetchFromGitHub
+, makeWrapper
+, scdoc
+, coreutils
+, util-linux
+, jq
+, libnotify
+, withHyprland ? true
+, hyprland
+}:
+
+stdenvNoCC.mkDerivation rec {
+  pname = "hdrop";
+  version = "0.2.4";
+
+  src = fetchFromGitHub {
+    owner = "Schweber";
+    repo = "hdrop";
+    rev = "v${version}";
+    hash = "sha256-VsM1wPl8edAnZUvYw3IeOHw/XQ2pvbLt0v3G0B8+iSA=";
+  };
+
+  nativeBuildInputs = [
+    makeWrapper
+    scdoc
+  ];
+
+  makeFlags = [ "PREFIX=$(out)" ];
+
+  postInstall = ''
+    wrapProgram $out/bin/hdrop --prefix PATH ':' \
+      "${lib.makeBinPath ([
+        coreutils
+        util-linux
+        jq
+        libnotify
+      ]
+      ++ lib.optional withHyprland hyprland)}"
+  '';
+
+  meta = with lib; {
+    description = "Emulate 'tdrop' in Hyprland (run, show and hide specific programs per keybind)";
+    homepage = "https://github.com/Schweber/hdrop";
+    changelog = "https://github.com/Schweber/hdrop/releases/tag/v${version}";
+    license = licenses.agpl3;
+    platforms = platforms.linux;
+    maintainers = with maintainers; [ Schweber ];
+    mainProgram = "hdrop";
+  };
+}