Fetch, flag/mark, delete/expire, and perform other batch operations on messages residing on IMAP servers. A very efficient KISS mail fetcher with cool security and convenience features.
{ pkgs ? import <nixpkgs> {}
, lib ? pkgs.lib
, developer ? false
}:
with pkgs.python3Packages;
buildPythonApplication (rec {
pname = "hoardy-mail";
version = "2.6.2";
format = "pyproject";
src = lib.cleanSourceWith {
src = ./.;
filter = name: type: let baseName = baseNameOf (toString name); in
lib.cleanSourceFilter name type
&& (builtins.match ".*.un~" baseName == null)
&& (baseName != "default.nix")
&& (baseName != "dist")
&& (baseName != "result")
&& (baseName != "results")
&& (baseName != "__pycache__")
&& (baseName != ".mypy_cache")
&& (baseName != ".pytest_cache")
;
};
propagatedBuildInputs = [
setuptools
];
} // lib.optionalAttrs developer {
nativeBuildInputs = [
build twine pip mypy pytest black pylint
pkgs.pandoc
];
preBuild = "find . ; black --check . && mypy && pylint hoardy_mail/__main__.py";
postInstall = "find $out";
})