2021-07-24 12:14:16 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
2022-06-26 10:26:21 +00:00
|
|
|
, fetchFromGitHub
|
2021-07-24 12:14:16 +00:00
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
|
|
|
, text-unidecode
|
|
|
|
, unidecode
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2021-07-24 12:14:16 +00:00
|
|
|
pname = "python-slugify";
|
2023-05-24 13:37:59 +00:00
|
|
|
version = "8.0.1";
|
2022-03-05 16:20:37 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
2023-05-24 13:37:59 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-06-26 10:26:21 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "un33k";
|
|
|
|
repo = pname;
|
2023-05-24 13:37:59 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
hash = "sha256-MJac63XjgWdUQdyyEm8O7gAGVszmHxZzRF4frJtR0BU=";
|
2021-07-24 12:14:16 +00:00
|
|
|
};
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-07-24 12:14:16 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
text-unidecode
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-05-24 13:37:59 +00:00
|
|
|
passthru.optional-dependencies = {
|
|
|
|
unidecode = [
|
|
|
|
unidecode
|
|
|
|
];
|
|
|
|
};
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-07-24 12:14:16 +00:00
|
|
|
pytestCheckHook
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-03-05 16:20:37 +00:00
|
|
|
pytestFlagsArray = [
|
|
|
|
"test.py"
|
|
|
|
];
|
2021-07-24 12:14:16 +00:00
|
|
|
|
2022-03-05 16:20:37 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"slugify"
|
|
|
|
];
|
2021-07-24 12:14:16 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python Slugify application that handles Unicode";
|
|
|
|
homepage = "https://github.com/un33k/python-slugify";
|
2023-05-24 13:37:59 +00:00
|
|
|
changelog = "https://github.com/un33k/python-slugify/blob/v${version}/CHANGELOG.md";
|
2021-07-24 12:14:16 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ vrthra ];
|
|
|
|
};
|
2020-04-24 23:36:52 +00:00
|
|
|
}
|