3
0
Fork 0
forked from mirrors/nixpkgs

Merge pull request #175019 from SuperSandro2000/django-model-utils

This commit is contained in:
Sandro 2022-05-28 16:45:11 +02:00 committed by GitHub
commit c017fda0a3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 55 additions and 0 deletions

View file

@ -0,0 +1,53 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, django
, freezegun
, psycopg2
, pytest-django
, pytestCheckHook
, pythonOlder
, setuptools-scm
}:
buildPythonPackage rec {
pname = "django-model-utils";
version = "4.2.0";
disabled = pythonOlder "3.6";
src = fetchFromGitHub {
owner = "jazzband";
repo = "django-model-utils";
rev = version;
sha256 = "sha256-TLqvpP/ZaGGFdqnN+UHbhXv1K1YVYTYBkCiWCjYrFh8=";
};
SETUPTOOLS_SCM_PRETEND_VERSION = version;
nativeBuildInputs = [
setuptools-scm
];
propagatedBuildInputs = [
django
];
# requires postgres database
doCheck = false;
checkInputs = [
freezegun
psycopg2
pytest-django
pytestCheckHook
];
pythonImportsCheck = [ "model_utils" ];
meta = with lib; {
homepage = "https://github.com/jazzband/django-model-utils";
description = "Django model mixins and utilities";
license = licenses.bsd3;
maintainers = with maintainers; [ SuperSandro2000 ];
};
}

View file

@ -2348,6 +2348,8 @@ in {
django-mailman3 = callPackage ../development/python-modules/django-mailman3 { };
django-model-utils = callPackage ../development/python-modules/django-model-utils { };
django-modelcluster = callPackage ../development/python-modules/django_modelcluster { };
django-multiselectfield = callPackage ../development/python-modules/django-multiselectfield { };