summary refs log tree commit diff
path: root/pkgs/applications/networking/instant-messengers/discord/linux.nix
diff options
context:
space:
mode:
authorAnund <anundm@gmail.com>2022-04-30 15:48:17 +1000
committerAnund <anundm@gmail.com>2022-04-30 15:58:27 +1000
commitb855d0a6aa7cbfe438eb993e9526f76000637163 (patch)
tree4f1278c72d9948a3140ae1858104b635e8c6853f /pkgs/applications/networking/instant-messengers/discord/linux.nix
parentb9387eced5da20a03c0f4f32ba4c4552620a0c69 (diff)
downloadnixpkgs-b855d0a6aa7cbfe438eb993e9526f76000637163.tar
nixpkgs-b855d0a6aa7cbfe438eb993e9526f76000637163.tar.gz
nixpkgs-b855d0a6aa7cbfe438eb993e9526f76000637163.tar.bz2
nixpkgs-b855d0a6aa7cbfe438eb993e9526f76000637163.tar.lz
nixpkgs-b855d0a6aa7cbfe438eb993e9526f76000637163.tar.xz
nixpkgs-b855d0a6aa7cbfe438eb993e9526f76000637163.tar.zst
nixpkgs-b855d0a6aa7cbfe438eb993e9526f76000637163.zip
discord: fix desktop icon location
${out}/share/pixmaps and $XDG_DATA_DIRS/share/pixmaps are not part
of the freedesktop icon theme spec. /usr/share/pixmaps is. There
are some packages that have been patched to recognize this non
standard path. Those packages may be depending this path so here
we only add the equivalent hicolor theme fallback path.

Without this change the discord icon won't be picked up by apps
attempting to follow the lookup pattern in the freedesktop spec.
Diffstat (limited to 'pkgs/applications/networking/instant-messengers/discord/linux.nix')
-rw-r--r--pkgs/applications/networking/instant-messengers/discord/linux.nix4
1 files changed, 3 insertions, 1 deletions
diff --git a/pkgs/applications/networking/instant-messengers/discord/linux.nix b/pkgs/applications/networking/instant-messengers/discord/linux.nix
index 05833c1eeaf..4ba0f6c86ca 100644
--- a/pkgs/applications/networking/instant-messengers/discord/linux.nix
+++ b/pkgs/applications/networking/instant-messengers/discord/linux.nix
@@ -71,7 +71,7 @@ stdenv.mkDerivation rec {
   ];
 
   installPhase = ''
-    mkdir -p $out/{bin,opt/${binaryName},share/pixmaps}
+    mkdir -p $out/{bin,opt/${binaryName},share/pixmaps,share/icons/hicolor/256x256/apps}
     mv * $out/opt/${binaryName}
 
     chmod +x $out/opt/${binaryName}/${binaryName}
@@ -89,7 +89,9 @@ stdenv.mkDerivation rec {
     ln -s $out/opt/${binaryName}/${binaryName} $out/bin/${
       lib.strings.toLower binaryName
     } || true
+
     ln -s $out/opt/${binaryName}/discord.png $out/share/pixmaps/${pname}.png
+    ln -s $out/opt/${binaryName}/discord.png $out/share/icons/hicolor/256x256/apps/${pname}.png
 
     ln -s "${desktopItem}/share/applications" $out/share/
   '';