mailnag: 1.3.0 -> 2.0.0

Notable changes:
- Switch to Python3 by default.
- Format inputs and arguments.
- Use wrapGAppsHook.
- Use libsecret (replaces libgnome-keyring) by default
- Add @doronbehar as maintainer.
- Remove overridden phases.
This commit is contained in:
Doron Behar 2020-04-25 04:03:21 +03:00
parent eeb4e522b5
commit a416707246
2 changed files with 44 additions and 26 deletions

@ -1,28 +1,49 @@
{ stdenv, fetchurl, gettext, gtk3, pythonPackages
, gdk-pixbuf, libnotify, gst_all_1
, libgnome-keyring3
, wrapGAppsHook, gnome3
# otherwise passwords are stored unencrypted
, withGnomeKeyring ? true
{ stdenv
, fetchFromGitHub
, gettext
, gtk3
, pythonPackages
, gdk-pixbuf
, libnotify
, gst_all_1
, libsecret
, wrapGAppsHook
, gsettings-desktop-schemas
, glib
, gobject-introspection
}:
let
inherit (pythonPackages) python;
in pythonPackages.buildPythonApplication rec {
pythonPackages.buildPythonApplication rec {
pname = "mailnag";
version = "1.3.0";
version = "2.0.0";
src = fetchurl {
url = "https://github.com/pulb/mailnag/archive/v${version}.tar.gz";
sha256 = "0cp5pad6jzd5c14pddbi9ap5bi78wjhk1x2p0gbblmvmcasw309s";
src = fetchFromGitHub {
owner = "pulb";
repo = "mailnag";
rev = "v${version}";
sha256 = "0q97v9i96br22z3h6r2mz79i68ib8m8x42yxky78szfrf8j60i30";
};
preFixup = ''
substituteInPlace $out/${pythonPackages.python.sitePackages}/Mailnag/common/dist_cfg.py \
--replace "/usr/" $out/
for desktop_file in $out/share/applications/*.desktop; do
substituteInPlace "$desktop_file" \
--replace "/usr/bin" $out/bin
done
'';
buildInputs = [
gtk3 gdk-pixbuf libnotify gst_all_1.gstreamer
gst_all_1.gst-plugins-base gst_all_1.gst-plugins-good
gtk3
gdk-pixbuf
glib
libnotify
gst_all_1.gstreamer
gst_all_1.gst-plugins-base
gst_all_1.gst-plugins-good
gst_all_1.gst-plugins-bad
gnome3.adwaita-icon-theme
] ++ stdenv.lib.optional withGnomeKeyring libgnome-keyring3;
gobject-introspection
libsecret
];
nativeBuildInputs = [
gettext
@ -30,20 +51,17 @@ in pythonPackages.buildPythonApplication rec {
];
propagatedBuildInputs = with pythonPackages; [
pygobject3 dbus-python pyxdg
gsettings-desktop-schemas
pygobject3
dbus-python
pyxdg
];
buildPhase = "";
installPhase = "${python}/bin/python setup.py install --prefix=$out";
doCheck = false;
meta = with stdenv.lib; {
description = "An extensible mail notification daemon";
homepage = "https://github.com/pulb/mailnag";
license = licenses.gpl2;
platforms = platforms.linux;
maintainers = with maintainers; [ ];
maintainers = with maintainers; [ doronbehar ];
};
}

@ -5047,7 +5047,7 @@ in
mailhog = callPackage ../servers/mail/mailhog {};
mailnag = callPackage ../applications/networking/mailreaders/mailnag {
pythonPackages = python2Packages;
pythonPackages = python3Packages;
};
mailsend = callPackage ../tools/networking/mailsend { };