nixpkgs/pkgs/development/python-modules/django-js-asset/default.nix
2026-06-14 18:37:16 +00:00

45 lines
982 B
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
hatchling,
django,
pytest-django,
pytestCheckHook,
}:
buildPythonPackage rec {
pname = "django-js-asset";
version = "4.0.1";
pyproject = true;
src = fetchFromGitHub {
owner = "matthiask";
repo = "django-js-asset";
tag = version;
hash = "sha256-TmoT+WuOw92wWW82CpKLy0Lr+oSKf+c2diG8Gs5rWg4=";
};
build-system = [ hatchling ];
dependencies = [ django ];
pythonImportsCheck = [ "js_asset" ];
nativeCheckInputs = [
pytest-django
pytestCheckHook
];
preCheck = ''
export DJANGO_SETTINGS_MODULE=tests.testapp.settings
'';
meta = {
changelog = "https://github.com/matthiask/django-js-asset/blob/${version}/CHANGELOG.rst";
description = "Script tag with additional attributes for django.forms.Media";
homepage = "https://github.com/matthiask/django-js-asset";
maintainers = with lib.maintainers; [ hexa ];
license = with lib.licenses; [ bsd3 ];
};
}