1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4
5# build-system
6, setuptools
7
8# dependencies
9, beautifulsoup4
10
11# tests
12, django
13, python
14}:
15
16buildPythonPackage rec {
17 pname = "django-bootstrap4";
18 version = "23.1";
19 format = "pyproject";
20
21 src = fetchFromGitHub {
22 owner = "zostera";
23 repo = "django-bootstrap4";
24 rev = "v${version}";
25 hash = "sha256-55pfUPwxDzpDn4stMEPvrQAexs+goN5SKFvwSR3J4aM=";
26 };
27
28 nativeBuildInputs = [
29 setuptools
30 ];
31
32 propagatedBuildInputs = [
33 beautifulsoup4
34 ];
35
36 pythonImportsCheck = [
37 "bootstrap4"
38 ];
39
40 nativeCheckInputs = [
41 (django.override { withGdal = true; })
42 ];
43
44 checkPhase = ''
45 runHook preCheck
46 ${python.interpreter} manage.py test -v1 --noinput
47 runHook postCheck
48 '';
49
50 meta = with lib; {
51 description = "Bootstrap 4 integration with Django";
52 homepage = "https://github.com/zostera/django-bootstrap4";
53 changelog = "https://github.com/zostera/django-bootstrap4/blob/${src.rev}/CHANGELOG.md";
54 license = licenses.bsd3;
55 maintainers = with maintainers; [ hexa ];
56 };
57}