2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
2020-04-24 23:36:52 +00:00
|
|
|
, buildPythonPackage
|
2021-12-30 13:39:12 +00:00
|
|
|
, fetchFromGitHub
|
2022-05-18 14:49:53 +00:00
|
|
|
, freezegun
|
|
|
|
, importlib-metadata
|
|
|
|
, pytestCheckHook
|
2021-12-30 13:39:12 +00:00
|
|
|
, pythonOlder
|
2021-02-16 17:04:54 +00:00
|
|
|
, setuptools
|
2022-05-18 14:49:53 +00:00
|
|
|
, setuptools-scm
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2022-05-18 14:49:53 +00:00
|
|
|
version = "4.1.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "humanize";
|
2021-12-30 13:39:12 +00:00
|
|
|
format = "pyproject";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-05-18 14:49:53 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
2021-12-30 13:39:12 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2022-05-18 14:49:53 +00:00
|
|
|
owner = "python-humanize";
|
2021-12-30 13:39:12 +00:00
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2022-05-18 14:49:53 +00:00
|
|
|
hash = "sha256-5xL3gfEohDjnF085Pgx/PBXWWM76X4FU2KR+8OGshMw=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-12-30 13:39:12 +00:00
|
|
|
SETUPTOOLS_SCM_PRETEND_VERSION = version;
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
setuptools-scm
|
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
setuptools
|
2022-05-18 14:49:53 +00:00
|
|
|
] ++ lib.optionals (pythonOlder "3.8") [
|
|
|
|
importlib-metadata
|
2021-12-30 13:39:12 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
freezegun
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-05-18 14:49:53 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"humanize"
|
|
|
|
];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Python humanize utilities";
|
2022-05-18 14:49:53 +00:00
|
|
|
homepage = "https://github.com/python-humanize/humanize";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.mit;
|
2021-02-16 17:04:54 +00:00
|
|
|
maintainers = with maintainers; [ rmcgibbo ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|