diff --git a/pkgs/development/python-modules/green/default.nix b/pkgs/development/python-modules/green/default.nix new file mode 100644 index 000000000000..fa09e4ded214 --- /dev/null +++ b/pkgs/development/python-modules/green/default.nix @@ -0,0 +1,26 @@ +{ lib, buildPythonPackage, fetchPypi, isPy3k, colorama, coverage, termstyle, unidecode, mock, backports_shutil_get_terminal_size }: + +buildPythonPackage rec { + pname = "green"; + version = "2.12.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "8cdd2934eff754c9664f373ee0d77cb1cb35dbbf3b719b8ae3b059718db875df"; + }; + + prePatch = '' + # See https://github.com/CleanCut/green/pull/182 + substituteInPlace setup.py --replace python-termstyle termstyle + ''; + + propagatedBuildInputs = [ + colorama coverage termstyle unidecode + ] ++ lib.optionals (!isPy3k) [ mock backports_shutil_get_terminal_size ]; + + meta = with lib; { + description = "Python test runner"; + homepage = https://github.com/CleanCut/green; + license = licenses.mit; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 48eb47890f2c..8cf6998420e9 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -20930,23 +20930,7 @@ EOF termstyle = callPackage ../development/python-modules/termstyle { }; - green = buildPythonPackage rec { - name = "green-${version}"; - version = "2.3.0"; - src = pkgs.fetchurl { - url = "mirror://pypi/g/green/${name}.tar.gz"; - sha256 = "1888khfl9yxb8yfxq9b48dxwplqlxx8s0l530z5j7c6bx74v08b4"; - }; - - propagatedBuildInputs = with self; [ termstyle colorama ]; - buildInputs = with self; [ mock ]; - - meta = { - description = "Python test runner"; - homepage = "https://github.com/CleanCut/green"; - license = licenses.mit; - }; - }; + green = callPackage ../development/python-modules/green { }; topydo = throw "python3Packages.topydo was moved to topydo"; # 2017-09-22