about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/django-js-asset/default.nix
blob: e7001d15a9a46766cd7df3ae753fe3567d193199 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
{ lib
, buildPythonPackage
, fetchFromGitHub
, django
, python
}:

buildPythonPackage rec {
  pname = "django-js-asset";
  version = "unstable-2021-06-07";
  format = "setuptools";

  src = fetchFromGitHub {
    owner = "matthiask";
    repo = pname;
    rev = "a186aa0b5721ca95da6cc032a2fb780a152f581b";
    sha256 = "141zxng0wwxalsi905cs8pdppy3ad717y3g4fkdxw4n3pd0fjp8r";
  };

  propagatedBuildInputs = [
    django
  ];

  pythonImportsCheck = [
    "js_asset"
  ];

  checkPhase = ''
    runHook preCheck
    ${python.interpreter} tests/manage.py test testapp
    runHook postCheck
  '';

  meta = with lib; {
    description = "Script tag with additional attributes for django.forms.Media";
    homepage = "https://github.com/matthiask/django-js-asset";
    maintainers = with maintainers; [ hexa ];
    license = with licenses; [ bsd3 ];
  };
}