1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-12-11 15:15:36 +00:00

todoist-electron: Use desktop icon

This commit is contained in:
Imran Hossain 2020-10-20 17:22:41 -04:00
parent 59455622b6
commit 8cfeba2bbc

View file

@ -13,7 +13,9 @@ stdenv.mkDerivation rec {
desktopItem = makeDesktopItem {
name = "Todoist";
exec = "todoist";
exec = "todoist %U";
icon = "todoist";
comment = "Todoist for Linux";
desktopName = "Todoist";
categories = "Utility";
};
@ -35,6 +37,7 @@ stdenv.mkDerivation rec {
in ''
mkdir -p "$out/bin"
mv opt "$out/"
mv usr/share "$out/share"
# Patch binary
patchelf \
@ -48,7 +51,8 @@ stdenv.mkDerivation rec {
# Desktop item
mkdir -p "$out/share"
ln -s "${desktopItem}/share/applications" "$out/share/applications"
rm -r "$out/share/applications"
cp -r "${desktopItem}/share/applications" "$out/share/applications"
'';
meta = with lib; {