discord: Fix missing desktop entry (closes #21045)
This commit is contained in:
parent
891e391cdb
commit
4af2328e5c
@ -1,17 +1,17 @@
|
||||
{ stdenv, fetchurl
|
||||
{ stdenv, fetchurl, makeDesktopItem
|
||||
, alsaLib, atk, cairo, cups, dbus, expat, fontconfig, freetype, gdk_pixbuf
|
||||
, glib, gnome2, gtk2, libnotify, libX11, libXcomposite, libXcursor, libXdamage
|
||||
, libXext, libXfixes, libXi, libXrandr, libXrender, libXtst, nspr, nss, pango
|
||||
, systemd, libXScrnSaver }:
|
||||
|
||||
let version = "0.0.11"; in
|
||||
stdenv.mkDerivation rec {
|
||||
|
||||
stdenv.mkDerivation {
|
||||
|
||||
name = "discord-${version}";
|
||||
pname = "discord";
|
||||
version = "0.0.11";
|
||||
name = "${pname}-${version}";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://cdn-canary.discordapp.com/apps/linux/${version}/discord-canary-${version}.tar.gz";
|
||||
url = "https://cdn-canary.discordapp.com/apps/linux/${version}/${pname}-canary-${version}.tar.gz";
|
||||
sha256 = "1lk53vm14vr5pb8xxcx6hinpc2mkdns2xxv0bfzxvlmhfr6d6y18";
|
||||
};
|
||||
|
||||
@ -23,7 +23,7 @@ stdenv.mkDerivation {
|
||||
];
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
mkdir -p $out/{bin,share/pixmaps}
|
||||
mv * $out
|
||||
|
||||
# Copying how adobe-reader does it,
|
||||
@ -33,11 +33,22 @@ stdenv.mkDerivation {
|
||||
$out/DiscordCanary
|
||||
|
||||
ln -s $out/DiscordCanary $out/bin/
|
||||
ln -s $out/discord.png $out/share/pixmaps
|
||||
|
||||
# Putting udev in the path won't work :(
|
||||
ln -s ${systemd.lib}/lib/libudev.so.1 $out
|
||||
ln -s "${desktopItem}/share/applications" $out/share/
|
||||
'';
|
||||
|
||||
desktopItem = makeDesktopItem {
|
||||
name = pname;
|
||||
exec = "DiscordCanary";
|
||||
icon = pname;
|
||||
desktopName = "Discord Canary";
|
||||
genericName = meta.description;
|
||||
categories = "Network;InstantMessaging;";
|
||||
};
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "All-in-one voice and text chat for gamers that’s free, secure, and works on both your desktop and phone";
|
||||
homepage = "https://discordapp.com/";
|
||||
|
Loading…
Reference in New Issue
Block a user