From 4005d8a26d6043841aa0039d720db9e831b6f8f3 Mon Sep 17 00:00:00 2001 From: Daiderd Jordan Date: Thu, 11 May 2017 22:50:32 +0200 Subject: [PATCH] python-flake8: 3.2.1 -> 3.3.0 --- .../python-modules/flake8/default.nix | 27 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 22 +-------------- 2 files changed, 28 insertions(+), 21 deletions(-) create mode 100644 pkgs/development/python-modules/flake8/default.nix diff --git a/pkgs/development/python-modules/flake8/default.nix b/pkgs/development/python-modules/flake8/default.nix new file mode 100644 index 000000000000..aec715328f9b --- /dev/null +++ b/pkgs/development/python-modules/flake8/default.nix @@ -0,0 +1,27 @@ +{ stdenv, buildPythonPackage, fetchPypi, pythonOlder +, mock, pytest, pytestrunner +, configparser, enum34, mccabe, pycodestyle, pyflakes +}: + +buildPythonPackage rec { + name = "${pname}-${version}"; + pname = "flake8"; + version = "3.3.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "04izn1q1lgbr408l9b3vkxqmpi6mq47bxwc0iwypb02mrxns41xr"; + }; + + buildInputs = [ pytest mock pytestrunner ]; + propagatedBuildInputs = [ pyflakes pycodestyle mccabe ] + ++ stdenv.lib.optionals (pythonOlder "3.4") [ enum34 ] + ++ stdenv.lib.optionals (pythonOlder "3.2") [ configparser ]; + + meta = with stdenv.lib; { + description = "Code checking using pep8 and pyflakes"; + homepage = http://pypi.python.org/pypi/flake8; + license = licenses.mit; + maintainers = with maintainers; [ garbas ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 5b5badd22a62..ddb4963f569c 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -11081,27 +11081,7 @@ in { }; }; - flake8 = buildPythonPackage rec { - name = "flake8-${version}"; - version = "3.2.1"; - - src = pkgs.fetchurl { - url = "mirror://pypi/f/flake8/${name}.tar.gz"; - sha256 = "c7c460b5aff3a2063c798a77af18ec70af3941d35a22e2e76965e3c0e0b36055"; - }; - - buildInputs = with self; [ pytest mock pytestrunner ]; - propagatedBuildInputs = with self; [ pyflakes pycodestyle mccabe ] - ++ optionals (pythonOlder "3.4") [ enum34 ] - ++ optionals (pythonOlder "3.2") [ configparser ]; - - meta = { - description = "Code checking using pep8 and pyflakes"; - homepage = http://pypi.python.org/pypi/flake8; - license = licenses.mit; - maintainers = with maintainers; [ garbas ]; - }; - }; + flake8 = callPackage ../development/python-modules/flake8 { }; flake8-blind-except = callPackage ../development/python-modules/flake8-blind-except { };