python3Packages.django-auditlog: init at 2.2.2

This commit is contained in:
Leona Maroni 2023-11-29 21:04:19 +01:00
parent e2fa3d6055
commit 496167b632
No known key found for this signature in database
GPG key ID: D5B08ADFC75E3605
2 changed files with 69 additions and 0 deletions

View file

@ -0,0 +1,67 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, setuptools
, setuptools-scm
, django
, python-dateutil
, freezegun
, psycopg2
, postgresql
, postgresqlTestHook
, python
}:
buildPythonPackage rec {
pname = "django-auditlog";
version = "2.2.2";
pyproject = true;
src = fetchFromGitHub {
owner = "jazzband";
repo = pname;
rev = "v${version}";
hash = "sha256-QHSGqtpkOgltAg+RlG/Ik3DfEjtSWt45sqlD+Zw4Bh0=";
};
env.SETUPTOOLS_SCM_PRETEND_VERSION = version;
nativeBuildInputs = [
setuptools
setuptools-scm
];
propagatedBuildInputs = [
django
python-dateutil
];
nativeCheckInputs = [
freezegun
psycopg2
postgresql
postgresqlTestHook
];
postgresqlTestUserOptions = "LOGIN SUPERUSER";
checkPhase = ''
runHook preCheck
TEST_DB_USER=$PGUSER \
TEST_DB_HOST=$PGHOST \
${python.interpreter} runtests.py
runHook postCheck
'';
pythonImportsCheck = [ "auditlog" ];
meta = with lib; {
changelog = "https://github.com/jazzband/django-auditlog/blob/v${version}/CHANGELOG.md";
description = "A Django app that keeps a log of changes made to an object";
downloadPage = "https://github.com/jazzband/django-auditlog";
license = licenses.mit;
maintainers = with maintainers; [ leona ];
};
}

View file

@ -2922,6 +2922,8 @@ self: super: with self; {
django-appconf = callPackage ../development/python-modules/django-appconf { }; django-appconf = callPackage ../development/python-modules/django-appconf { };
django-auditlog = callPackage ../development/python-modules/django-auditlog { };
django-auth-ldap = callPackage ../development/python-modules/django-auth-ldap { }; django-auth-ldap = callPackage ../development/python-modules/django-auth-ldap { };
django-autocomplete-light = callPackage ../development/python-modules/django-autocomplete-light { }; django-autocomplete-light = callPackage ../development/python-modules/django-autocomplete-light { };