1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 pythonOlder, 6 stdenv, 7 packaging, 8 setuptools, 9 dbus-next, 10 rubicon-objc, 11}: 12 13buildPythonPackage rec { 14 pname = "desktop-notifier"; 15 version = "4.0.0"; 16 pyproject = true; 17 18 disabled = pythonOlder "3.7"; 19 20 src = fetchFromGitHub { 21 owner = "SamSchott"; 22 repo = pname; 23 rev = "refs/tags/v${version}"; 24 hash = "sha256-6FtxfY0vjCbCueeXdAXOy6XSjne4I7brQ5OvJ+Q1KsQ="; 25 }; 26 27 build-system = [ setuptools ]; 28 29 dependencies = 30 [ packaging ] 31 ++ lib.optionals stdenv.isLinux [ dbus-next ] 32 ++ lib.optionals stdenv.hostPlatform.isDarwin [ rubicon-objc ]; 33 34 # no tests available, do the imports check instead 35 doCheck = false; 36 37 pythonImportsCheck = [ "desktop_notifier" ]; 38 39 meta = with lib; { 40 description = "Python library for cross-platform desktop notifications"; 41 homepage = "https://github.com/samschott/desktop-notifier"; 42 changelog = "https://github.com/samschott/desktop-notifier/releases/tag/v${version}"; 43 license = licenses.mit; 44 maintainers = with maintainers; [ sfrijters ]; 45 }; 46}