forked from mirrors/nixpkgs
4a7f99d55d
Part of: https://github.com/NixOS/nixpkgs/issues/108938 meta = with stdenv.lib; is a widely used pattern. We want to slowly remove the `stdenv.lib` indirection and encourage people to use `lib` directly. Thus let’s start with the meta field. This used a rewriting script to mostly automatically replace all occurances of this pattern, and add the `lib` argument to the package header if it doesn’t exist yet. The script in its current form is available at https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
52 lines
1.3 KiB
Nix
52 lines
1.3 KiB
Nix
{ lib, stdenv
|
|
, fetchurl
|
|
, autoPatchelfHook
|
|
, gtk3
|
|
, gobject-introspection
|
|
, libxml2
|
|
}:
|
|
|
|
let
|
|
version = "1.7.2";
|
|
|
|
dbusService = fetchurl {
|
|
url = "https://github.com/phuhl/linux_notification_center/raw/${version}/com.ph-uhl.deadd.notification.service.in";
|
|
sha256 = "0jvmi1c98hm8x1x7kw9ws0nbf4y56yy44c3bqm6rjj4lrm89l83s";
|
|
};
|
|
in
|
|
stdenv.mkDerivation rec {
|
|
inherit version;
|
|
pname = "deadd-notification-center";
|
|
|
|
src = fetchurl {
|
|
url = "https://github.com/phuhl/linux_notification_center/releases/download/${version}/${pname}";
|
|
sha256 = "13f15slkjiw2n5dnqj13dprhqm3nf1k11jqaqda379yhgygyp9zm";
|
|
};
|
|
|
|
dontUnpack = true;
|
|
|
|
nativeBuildInputs = [ autoPatchelfHook ];
|
|
|
|
buildInputs = [
|
|
gtk3
|
|
gobject-introspection
|
|
libxml2
|
|
];
|
|
|
|
installPhase = ''
|
|
mkdir -p $out/bin $out/share/dbus-1/services
|
|
cp $src $out/bin/deadd-notification-center
|
|
chmod +x $out/bin/deadd-notification-center
|
|
|
|
sed "s|##PREFIX##|$out|g" ${dbusService} > $out/share/dbus-1/services/com.ph-uhl.deadd.notification.service
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "A haskell-written notification center for users that like a desktop with style";
|
|
homepage = "https://github.com/phuhl/linux_notification_center";
|
|
license = licenses.bsd3;
|
|
maintainers = [ maintainers.pacman99 ];
|
|
platforms = platforms.linux;
|
|
};
|
|
}
|