2020-03-30 06:27:45 +00:00
|
|
|
{ stdenv
|
|
|
|
, lib
|
|
|
|
, fetchFromGitHub
|
|
|
|
, makeWrapper
|
|
|
|
|
|
|
|
, autoreconfHook
|
2021-01-17 02:09:27 +00:00
|
|
|
, pkg-config
|
2020-03-30 06:27:45 +00:00
|
|
|
|
2024-03-26 10:42:43 +00:00
|
|
|
, waylandSupport ? true
|
|
|
|
, x11Support ? true
|
|
|
|
|
2020-03-30 06:27:45 +00:00
|
|
|
, cairo
|
|
|
|
, glib
|
|
|
|
, libnotify
|
|
|
|
, rofi-unwrapped
|
|
|
|
, wl-clipboard
|
|
|
|
, xclip
|
2024-03-26 10:42:43 +00:00
|
|
|
, xdotool
|
|
|
|
, wtype
|
2020-03-30 06:27:45 +00:00
|
|
|
}:
|
|
|
|
|
2024-07-23 21:49:20 +00:00
|
|
|
import ./versions.nix ({ version, hash, patches}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "rofi-emoji";
|
|
|
|
inherit version;
|
2020-03-30 06:27:45 +00:00
|
|
|
|
2024-07-23 21:49:20 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Mange";
|
|
|
|
repo = "rofi-emoji";
|
|
|
|
rev = "v${version}";
|
|
|
|
inherit hash;
|
|
|
|
};
|
2020-03-30 06:27:45 +00:00
|
|
|
|
2024-07-23 21:49:20 +00:00
|
|
|
inherit patches;
|
2020-03-30 06:27:45 +00:00
|
|
|
|
2024-07-23 21:49:20 +00:00
|
|
|
postPatch = ''
|
|
|
|
patchShebangs clipboard-adapter.sh
|
|
|
|
'';
|
2020-03-30 06:27:45 +00:00
|
|
|
|
2024-07-23 21:49:20 +00:00
|
|
|
postFixup = ''
|
|
|
|
chmod +x $out/share/rofi-emoji/clipboard-adapter.sh
|
|
|
|
wrapProgram $out/share/rofi-emoji/clipboard-adapter.sh \
|
|
|
|
--prefix PATH ":" ${lib.makeBinPath ([ libnotify ]
|
|
|
|
++ lib.optionals waylandSupport [ wl-clipboard wtype ]
|
|
|
|
++ lib.optionals x11Support [ xclip xdotool ])}
|
|
|
|
'';
|
2020-03-30 06:27:45 +00:00
|
|
|
|
2024-03-26 10:42:43 +00:00
|
|
|
|
2024-07-23 21:49:20 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
autoreconfHook
|
|
|
|
pkg-config
|
|
|
|
makeWrapper
|
|
|
|
];
|
2020-03-30 06:27:45 +00:00
|
|
|
|
2024-07-23 21:49:20 +00:00
|
|
|
buildInputs = [
|
|
|
|
cairo
|
|
|
|
glib
|
|
|
|
libnotify
|
|
|
|
rofi-unwrapped
|
|
|
|
]
|
|
|
|
++ lib.optionals waylandSupport [ wl-clipboard wtype ]
|
|
|
|
++ lib.optionals x11Support [ xclip ];
|
2020-03-30 06:27:45 +00:00
|
|
|
|
2024-07-23 21:49:20 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Emoji selector plugin for Rofi (built against ${rofi-unwrapped.pname})";
|
|
|
|
homepage = "https://github.com/Mange/rofi-emoji";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ cole-h Mange ];
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|
|
|
|
)
|