2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv
|
2019-08-06 15:54:14 +01:00
|
|
|
, buildPythonPackage
|
|
|
|
, django
|
|
|
|
, netaddr
|
|
|
|
, six
|
|
|
|
, fetchFromGitHub
|
|
|
|
# required for tests
|
|
|
|
#, djangorestframework
|
|
|
|
#, psycopg2
|
|
|
|
#, unittest2
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
version = "1.2.2";
|
|
|
|
pname = "django-postgresql-netfields";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "jimfunk";
|
2020-11-01 22:39:49 +00:00
|
|
|
repo = pname;
|
2019-08-06 15:54:14 +01:00
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "1rrh38f3zl3jk5ijs6g75dxxvxygf4lczbgc7ahrgzf58g4a48lm";
|
|
|
|
};
|
|
|
|
|
|
|
|
# tests need a postgres database
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
# keeping the dependencies below as comment for reference
|
|
|
|
# checkPhase = ''
|
|
|
|
# python manage.py test
|
|
|
|
# '';
|
|
|
|
|
|
|
|
# buildInputs = [
|
|
|
|
# djangorestframework
|
|
|
|
# psycopg2
|
|
|
|
# unittest2
|
|
|
|
# ];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
django
|
|
|
|
netaddr
|
|
|
|
six
|
|
|
|
];
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2019-08-06 15:54:14 +01:00
|
|
|
description = "Django PostgreSQL netfields implementation";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/jimfunk/django-postgresql-netfields";
|
2019-08-06 15:54:14 +01:00
|
|
|
license = licenses.bsd2;
|
|
|
|
};
|
|
|
|
}
|