depot/third_party/nixpkgs/pkgs/development/python-modules/titlecase/default.nix
Default email e7ec2969af Project import generated by Copybara.
GitOrigin-RevId: 9b19f5e77dd906cb52dade0b7bd280339d2a1f3d
2024-01-13 09:15:51 +01:00

50 lines
917 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, pytestCheckHook
, pythonOlder
, regex
, setuptools-scm
}:
buildPythonPackage rec {
pname = "titlecase";
version = "2.4";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "ppannuto";
repo = "python-titlecase";
rev = "refs/tags/v${version}";
hash = "sha256-aJbbfNnQvmmYPXVOO+xx7ADetsxE+jnVQOVDzV5jUp8=";
};
nativeBuildInputs = [
setuptools-scm
];
propagatedBuildInputs = [
regex
];
nativeCheckInputs = [
pytestCheckHook
];
pytestFlagsArray = [
"titlecase/tests.py"
];
pythonImportsCheck = [
"titlecase"
];
meta = with lib; {
description = "Python library to capitalize strings as specified by the New York Times";
homepage = "https://github.com/ppannuto/python-titlecase";
license = licenses.mit;
maintainers = with maintainers; [ ];
};
}