2020-04-24 23:36:52 +00:00
|
|
|
{ buildPythonPackage
|
|
|
|
, lib
|
|
|
|
, fetchPypi
|
|
|
|
, docopt
|
|
|
|
, delegator-py
|
|
|
|
, pytest
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2022-09-30 11:47:45 +00:00
|
|
|
version = "0.5.12";
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "num2words";
|
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2023-03-15 16:39:30 +00:00
|
|
|
hash = "sha256-fnwLDwgEBao6HdnTKxypCzvwO6sXuOVNsF4beDAaCYg=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ docopt ];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [ delegator-py pytest ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
pytest -k 'not cli_with_lang'
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Modules to convert numbers to words. 42 --> forty-two";
|
|
|
|
homepage = "https://github.com/savoirfairelinux/num2words";
|
|
|
|
license = licenses.lgpl21;
|
|
|
|
maintainers = with maintainers; [ jonringer ];
|
|
|
|
|
|
|
|
longDescription =
|
|
|
|
"num2words is a library that converts numbers like 42 to words like forty-two. It supports multiple languages (see the list below for full list of languages) and can even generate ordinal numbers like forty-second";
|
|
|
|
};
|
|
|
|
}
|