From 7b5608e5bd7d5197e76f568e54dc3596cfbead3d Mon Sep 17 00:00:00 2001 From: Schweber <64630479+Schweber@users.noreply.github.com> Date: Sat, 2 Dec 2023 18:49:45 +0100 Subject: [PATCH 1/2] maintainers: add Schweber --- maintainers/maintainer-list.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index 4678aeb8811a..2ea8003a0340 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -16213,6 +16213,11 @@ githubId = 5104601; name = "schnusch"; }; + Schweber = { + github = "Schweber"; + githubId = 64630479; + name = "Schweber"; + }; sciencentistguy = { email = "jamie@quigley.xyz"; name = "Jamie Quigley"; From fb95efda8e00dd4307b3caeffce969d956eabee4 Mon Sep 17 00:00:00 2001 From: Schweber <64630479+Schweber@users.noreply.github.com> Date: Sat, 2 Dec 2023 18:49:55 +0100 Subject: [PATCH 2/2] hdrop: init at 0.2.4 hdrop: format package.nix with nixpkgs-fmt hdrop: fix formatting again hdrop: improve formatting --- pkgs/by-name/hd/hdrop/package.nix | 52 +++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100755 pkgs/by-name/hd/hdrop/package.nix 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"; + }; +}