rofi-emoji: move to pkgs/by-name, use v4

This commit is contained in:
Acid Bong
2025-10-22 14:30:04 +03:00
parent 2e28c9f6db
commit d17e964c45
5 changed files with 86 additions and 113 deletions
@@ -1,93 +0,0 @@
{
stdenv,
lib,
fetchFromGitHub,
makeWrapper,
autoreconfHook,
pkg-config,
waylandSupport ? true,
x11Support ? true,
cairo,
glib,
libnotify,
rofi-unwrapped,
wl-clipboard,
xclip,
xdotool,
wtype,
}:
import ./versions.nix (
{
version,
hash,
patches,
}:
stdenv.mkDerivation rec {
pname = "rofi-emoji";
inherit version;
src = fetchFromGitHub {
owner = "Mange";
repo = "rofi-emoji";
rev = "v${version}";
inherit hash;
};
inherit patches;
postPatch = ''
patchShebangs clipboard-adapter.sh
'';
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
]
)
}
'';
nativeBuildInputs = [
autoreconfHook
pkg-config
makeWrapper
];
buildInputs = [
cairo
glib
libnotify
rofi-unwrapped
]
++ lib.optionals waylandSupport [
wl-clipboard
wtype
]
++ lib.optionals x11Support [ xclip ];
meta = with lib; {
description = "Emoji selector plugin for Rofi";
homepage = "https://github.com/Mange/rofi-emoji";
license = licenses.mit;
maintainers = with maintainers; [
cole-h
Mange
];
platforms = platforms.linux;
};
}
)
@@ -1,18 +0,0 @@
generic: {
v4 = generic {
version = "4.0.0";
hash = "sha256-864Mohxfc3EchBKtSNifxy8g8T8YBUQ/H7+8Ti6TiFo=";
patches = [
# Look for plugin-related files in $out/lib/rofi
./0001-Patch-plugindir-to-output.patch
];
};
v3 = generic {
version = "3.4.1";
hash = "sha256-ZHhgYytPB14zj2MS8kChRD+LTqXzHRrz7YIikuQD6i0=";
patches = [
# Look for plugin-related files in $out/lib/rofi
./0001-Patch-plugindir-to-output.patch
];
};
}
+86
View File
@@ -0,0 +1,86 @@
{
stdenv,
lib,
fetchFromGitHub,
makeWrapper,
autoreconfHook,
pkg-config,
cairo,
glib,
libnotify,
rofi-unwrapped,
x11Support ? true,
xclip,
xdotool,
waylandSupport ? true,
wl-clipboard,
wtype,
}:
stdenv.mkDerivation (final: {
pname = "rofi-emoji";
version = "4.0.0";
src = fetchFromGitHub {
owner = "Mange";
repo = "rofi-emoji";
rev = "v${final.version}";
hash = "sha256-864Mohxfc3EchBKtSNifxy8g8T8YBUQ/H7+8Ti6TiFo=";
};
patches = [
# Look for plugin-related files in $out/lib/rofi
./0001-Patch-plugindir-to-output.patch
];
postPatch = ''
patchShebangs --host clipboard-adapter.sh
'';
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
]
)
}
'';
nativeBuildInputs = [
autoreconfHook
pkg-config
makeWrapper
];
buildInputs = [
cairo
glib
rofi-unwrapped
];
meta = {
description = "Emoji selector plugin for Rofi";
homepage = "https://github.com/Mange/rofi-emoji";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [
cole-h
Mange
];
platforms = lib.platforms.linux;
};
})
-2
View File
@@ -11837,8 +11837,6 @@ with pkgs;
withConplay = false;
};
rofi-emoji = (callPackage ../applications/misc/rofi-emoji { }).v3;
# a somewhat more maintained fork of ympd
memento = qt6Packages.callPackage ../applications/video/memento { };