2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pytestCheckHook,
|
2021-05-20 23:08:51 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "timeago";
|
2023-03-15 16:39:30 +00:00
|
|
|
version = "1.0.16";
|
2024-01-02 11:29:13 +00:00
|
|
|
format = "setuptools";
|
2021-05-20 23:08:51 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "hustcc";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2023-03-15 16:39:30 +00:00
|
|
|
sha256 = "sha256-PqORJKAVrjezU/yP2ky3gb1XsM8obDI3GQzi+mok/OM=";
|
2021-05-20 23:08:51 +00:00
|
|
|
};
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
2021-05-20 23:08:51 +00:00
|
|
|
|
|
|
|
pytestFlagsArray = [ "test/testcase.py" ];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "timeago" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python module to format past datetime output";
|
|
|
|
homepage = "https://github.com/hustcc/timeago";
|
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|