nixpkgs/pkgs/development/python-modules/caldav/default.nix

60 lines
1.0 KiB
Nix
Raw Normal View History

2020-04-21 14:41:59 +00:00
{ lib
, buildPythonPackage
, fetchFromGitHub
, pythonOlder
, icalendar
2020-04-21 14:41:59 +00:00
, lxml
, nose
, pytz
, requests
, six
, tzlocal
, vobject
2020-04-21 14:41:59 +00:00
}:
2019-04-29 08:49:35 +00:00
buildPythonPackage rec {
pname = "caldav";
2021-12-26 23:42:23 +00:00
version = "0.8.2";
2019-04-29 08:49:35 +00:00
src = fetchFromGitHub {
owner = "python-caldav";
repo = pname;
rev = "v${version}";
2021-12-26 23:42:23 +00:00
hash = "sha256-2mpE1aLipps4X/3EF0oKHXDcrgUh78/fxY6y1B1V2IU=";
2019-04-29 08:49:35 +00:00
};
2021-12-26 23:42:23 +00:00
propagatedBuildInputs = [
vobject
lxml
requests
six
];
checkInputs = [
icalendar
nose
tzlocal
2021-12-26 23:42:23 +00:00
pytz
];
checkPhase = ''
nosetests tests
'';
# xandikos and radicale is only a optional test dependency, not available for python3
2020-04-21 14:41:59 +00:00
postPatch = ''
substituteInPlace setup.py \
2021-12-26 23:42:23 +00:00
--replace ", 'xandikos<0.2.4'" "" \
--replace ", 'radicale'" ""
2020-04-21 14:41:59 +00:00
'';
pythonImportsCheck = [ "caldav" ];
2019-04-29 08:49:35 +00:00
meta = with lib; {
description = "This project is a CalDAV (RFC4791) client library for Python.";
homepage = "https://github.com/python-caldav/caldav";
2019-04-29 08:49:35 +00:00
license = licenses.asl20;
2021-12-26 23:42:23 +00:00
maintainers = with maintainers; [ marenz dotlambda ];
2019-04-29 08:49:35 +00:00
};
}