1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, django
5, python
6}:
7
8buildPythonPackage rec {
9 pname = "django-js-asset";
10 version = "2.0";
11 format = "setuptools";
12
13 src = fetchFromGitHub {
14 owner = "matthiask";
15 repo = pname;
16 rev = "refs/tags/${version}";
17 hash = "sha256-YDOmbqB0xDBAlOSO1UBYJ8VfRjJ8Z6Hw1i24DNSrnjw=";
18 };
19
20 propagatedBuildInputs = [
21 django
22 ];
23
24 pythonImportsCheck = [
25 "js_asset"
26 ];
27
28 checkPhase = ''
29 runHook preCheck
30 ${python.interpreter} tests/manage.py test testapp
31 runHook postCheck
32 '';
33
34 meta = with lib; {
35 description = "Script tag with additional attributes for django.forms.Media";
36 homepage = "https://github.com/matthiask/django-js-asset";
37 maintainers = with maintainers; [ hexa ];
38 license = with licenses; [ bsd3 ];
39 };
40}