1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 flake8,
6 python,
7 pythonOlder,
8}:
9
10buildPythonPackage rec {
11 pname = "pep8-naming";
12 version = "0.13.3";
13 format = "setuptools";
14
15 disabled = pythonOlder "3.7";
16
17 src = fetchFromGitHub {
18 owner = "PyCQA";
19 repo = pname;
20 rev = version;
21 hash = "sha256-l7zZUOMWyTxnTbkFkzfABY/eVMKnv0kNJ0UPzJo0W1Y=";
22 };
23
24 propagatedBuildInputs = [ flake8 ];
25
26 checkPhase = ''
27 runHook preCheck
28 ${python.interpreter} run_tests.py
29 runHook postCheck
30 '';
31
32 pythonImportsCheck = [ "pep8ext_naming" ];
33
34 meta = with lib; {
35 description = "Check PEP-8 naming conventions, plugin for flake8";
36 homepage = "https://github.com/PyCQA/pep8-naming";
37 changelog = "https://github.com/PyCQA/pep8-naming/blob/${version}/CHANGELOG.rst";
38 license = licenses.mit;
39 maintainers = with maintainers; [ eadwu ];
40 };
41}