blob: cfdce46a30fb826b4a3d692d15e872ce0fd0f233 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
{
lib,
buildPythonPackage,
fetchFromGitHub,
setuptools,
libnotify,
pytestCheckHook,
}:
buildPythonPackage rec {
pname = "pynotifier";
version = "0.5.0";
pyproject = true;
src = fetchFromGitHub {
owner = "YuriyLisovskiy";
repo = "pynotifier";
rev = version;
hash = "sha256-xS3hH3cyqgDD7uoWkIYXpQAh7SN7XJ/qMfB0Vq5bva0=";
};
postPatch = ''
substituteInPlace pynotifier/backends/platform/linux.py \
--replace-fail \
'shutil.which("notify-send")' \
'"${lib.getExe' libnotify "notify-send"}"'
'';
nativeBuildInputs = [ setuptools ];
nativeCheckInputs = [ pytestCheckHook ];
pythonImportsCheck = [ "pynotifier" ];
meta = {
description = "Module for sending notifications";
homepage = "https://github.com/YuriyLisovskiy/pynotifier";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ pbsds ];
};
}
|