2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
fetchFromGitHub,
|
|
|
|
buildPythonPackage,
|
|
|
|
click,
|
|
|
|
dawg-python,
|
|
|
|
docopt,
|
|
|
|
pytestCheckHook,
|
|
|
|
pymorphy3-dicts-ru,
|
|
|
|
pymorphy3-dicts-uk,
|
2023-03-04 12:14:45 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pymorphy3";
|
2024-04-21 15:54:59 +00:00
|
|
|
version = "2.0.1";
|
2024-01-02 11:29:13 +00:00
|
|
|
format = "setuptools";
|
2023-03-04 12:14:45 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "no-plagiarism";
|
|
|
|
repo = pname;
|
2023-11-16 04:20:00 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2024-04-21 15:54:59 +00:00
|
|
|
hash = "sha256-AIAccIxv3lCZcTKHfE/s2n3A5fUWqon+dk0SvczritY=";
|
2023-03-04 12:14:45 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
dawg-python
|
|
|
|
docopt
|
|
|
|
pymorphy3-dicts-ru
|
|
|
|
pymorphy3-dicts-uk
|
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
optional-dependencies.CLI = [ click ];
|
2024-04-21 15:54:59 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
nativeCheckInputs = [ pytestCheckHook ] ++ optional-dependencies.CLI;
|
2023-03-04 12:14:45 +00:00
|
|
|
|
|
|
|
pythonImportsCheck = [ "pymorphy3" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Morphological analyzer/inflection engine for Russian and Ukrainian";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "pymorphy";
|
2023-03-04 12:14:45 +00:00
|
|
|
homepage = "https://github.com/no-plagiarism/pymorphy3";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ jboy ];
|
|
|
|
};
|
|
|
|
}
|