nixpkgs/pkgs/development/python-modules/django-widget-tweaks/default.nix
Martin Weinelt 8056f9250c
treewide: remove redundant SETUPTOOLS_SCM_PRETEND_VERSION usage
The setuptools-scm packages gained a setup hook, that sets it to the
derivation version automatically, so setting it to that manually has
become redundant.

This also affects downstream consumers of setuptools-scm, like hatch-vcs
or flit-scm.
2023-12-20 20:16:39 +01:00

44 lines
966 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, setuptools-scm
, django
, python
, pythonOlder
}:
buildPythonPackage rec {
pname = "django-widget-tweaks";
version = "1.5.0";
format = "setuptools";
disabled = pythonOlder "3.8";
src = fetchFromGitHub {
owner = "jazzband";
repo = pname;
rev = "refs/tags/${version}";
hash = "sha256-/3UIsg75X3R9YGv9cEcoPw3IN2vkhUb+HCy68813d2E=";
};
nativeBuildInputs = [
setuptools-scm
];
propagatedBuildInputs = [
django
];
checkPhase = ''
${python.interpreter} -m django test --settings=tests.settings
'';
meta = with lib; {
description = "Tweak the form field rendering in templates, not in python-level form definitions";
homepage = "https://github.com/jazzband/django-widget-tweaks";
changelog = "https://github.com/jazzband/django-widget-tweaks/blob/${version}/CHANGES.rst";
license = licenses.mit;
maintainers = with maintainers; [ maxxk ];
};
}