summary refs log tree commit diff
path: root/pkgs/development/python-modules/django_compressor/default.nix
blob: edf5faa5af40b9da2f16069fdd4d35d71bc41ef0 (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
{ lib, buildPythonPackage, fetchPypi,
  rcssmin, rjsmin, django_appconf }:
buildPythonPackage rec {
    pname = "django_compressor";
    version = "2.4";

    src = fetchPypi {
      inherit pname version;
      sha256 = "0kx7bclfa0sxlsz6ka70zr9ra00lks0hmv1kc99wbanx6xhirvfj";
    };
    postPatch = ''
      substituteInPlace setup.py --replace 'rcssmin == 1.0.6' 'rcssmin' \
        --replace 'rjsmin == 1.0.12' 'rjsmin'
    '';

    # requires django-sekizai, which we don't have packaged yet
    doCheck = false;

    propagatedBuildInputs = [ rcssmin rjsmin django_appconf ];

    meta = with lib; {
      description = "Compresses linked and inline JavaScript or CSS into single cached files";
      homepage = "https://django-compressor.readthedocs.org/en/latest/";
      license = licenses.mit;
      maintainers = with maintainers; [ desiderius ];
    };
}