key-mapper: Fix desktop item

This commit is contained in:
PapaTutuWawa 2021-09-06 15:43:55 +02:00
parent 2e67b964f8
commit d3fdbf0683

View File

@ -1,4 +1,10 @@
{ pkgs, lib, python3Packages, python3, gtk3, gobject-introspection, git, wrapGAppsHook, gnome, makeDesktopItem }:
{
pkgs, lib
, python3Packages, python3
, gtk3, gobject-introspection, git, gnome
, wrapGAppsHook
, makeDesktopItem
}:
python3Packages.buildPythonApplication rec {
pname = "key-mapper";
@ -35,10 +41,16 @@ python3Packages.buildPythonApplication rec {
${python3}/bin/${python3.executable} setup.py install_data --install-dir=$out --root=$out
'';
postInstall = ''
mkdir -p $out/share/icons/hicolor/scalable/apps/
cp -r ${desktopItem}/share/applications $out/share/
cp $out/usr/share/key-mapper/key-mapper.svg $out/share/icons/hicolor/scalable/apps/key-mapper.svg
'';
desktopItem = makeDesktopItem {
name = "key-mapper";
exec = "$out/bin/key-mapper-gtk";
icon = "$out/usr/share/key-mapper/key-mapper.svg";
exec = "key-mapper-gtk";
icon = "key-mapper";
desktopName = "key-mapper";
genericName = "key-mapper";
};