2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
2021-03-12 07:09:13 +00:00
|
|
|
, isPy27
|
2021-02-05 17:12:51 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
, pymeeus
|
|
|
|
, pytz
|
|
|
|
, pytestCheckHook
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "convertdate";
|
2021-03-15 08:37:03 +00:00
|
|
|
version = "2.3.2";
|
2021-03-12 07:09:13 +00:00
|
|
|
disabled = isPy27;
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
# Tests are not available in the PyPI tarball so use GitHub instead.
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "fitnr";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-03-15 08:37:03 +00:00
|
|
|
sha256 = "0k7j59sbqwyi72vcjx5vsh3qb6hxfnkfjkd2i6f6lckdr1bkh7fz";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
pymeeus
|
|
|
|
pytz
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-03-15 08:37:03 +00:00
|
|
|
pythonImportsCheck = [ "convertdate" ];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/fitnr/convertdate";
|
|
|
|
description = "Utils for converting between date formats and calculating holidays";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ jluttine ];
|
|
|
|
};
|
|
|
|
}
|