Files
nixpkgs/pkgs/development/python-modules/cookiecutter/default.nix
Fabian Affolter 186e316b6e python3Packages.cookiecutter: 2.6.0 -> 2.7.1
https://github.com/cookiecutter/cookiecutter/blob/2.7.1/HISTORY.md

This commit was automatically generated using update-python-libraries.
2026-08-25 01:24:16 +02:00

86 lines
1.5 KiB
Nix

{
lib,
buildPythonPackage,
fetchPypi,
isPyPy,
bash,
setuptools,
pytestCheckHook,
pytest-cov-stub,
pytest-mock,
freezegun,
git,
jinja2,
binaryornot,
click,
jinja2-time,
requests,
python-slugify,
pyyaml,
arrow,
rich,
}:
buildPythonPackage rec {
pname = "cookiecutter";
version = "2.7.1";
pyproject = true;
# not sure why this is broken
disabled = isPyPy;
src = fetchPypi {
inherit pname version;
hash = "sha256-ynu3vIxv9EH79TkhtVN2aAAOONVuKNdjobc5dcZsYTg=";
};
postPatch = ''
patchShebangs tests/test-pyshellhooks/hooks tests/test-shellhooks/hooks
substituteInPlace tests/test_hooks.py \
--replace-fail "/bin/bash" "${lib.getExe bash}"
'';
build-system = [ setuptools ];
nativeCheckInputs = [
pytestCheckHook
pytest-cov-stub
pytest-mock
freezegun
git
];
dependencies = [
binaryornot
jinja2
click
pyyaml
jinja2-time
python-slugify
requests
arrow
rich
];
pythonImportsCheck = [ "cookiecutter.main" ];
preCheck = ''
export HOME="$(mktemp -d)"
'';
disabledTests = [
# messes with $PYTHONPATH
"test_should_invoke_main"
];
meta = {
homepage = "https://github.com/audreyr/cookiecutter";
changelog = "https://github.com/cookiecutter/cookiecutter/blob/${version}/HISTORY.md";
description = "Command-line utility that creates projects from project templates";
mainProgram = "cookiecutter";
license = lib.licenses.bsd3;
maintainers = with lib.maintainers; [ kragniz ];
};
}