2021-02-24 17:10:34 -08:00
|
|
|
{ stdenv
|
|
|
|
, lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, pythonOlder
|
|
|
|
, installShellFiles
|
|
|
|
, astroid
|
|
|
|
, isort
|
|
|
|
, mccabe
|
|
|
|
, toml
|
|
|
|
, pytest-benchmark
|
|
|
|
, pytest-xdist
|
|
|
|
, pytestCheckHook
|
|
|
|
}:
|
2017-03-02 17:51:55 -08:00
|
|
|
|
2017-09-06 08:28:21 -07:00
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pylint";
|
2021-03-24 02:28:22 -07:00
|
|
|
version = "2.7.2";
|
2018-07-24 08:53:48 -07:00
|
|
|
|
2021-02-24 17:10:34 -08:00
|
|
|
disabled = pythonOlder "3.6";
|
2017-09-06 08:28:21 -07:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2021-03-24 02:28:22 -07:00
|
|
|
sha256 = "0e21d3b80b96740909d77206d741aa3ce0b06b41be375d92e1f3244a274c1f8a";
|
2017-09-06 08:28:21 -07:00
|
|
|
};
|
|
|
|
|
2021-02-24 17:10:34 -08:00
|
|
|
nativeBuildInputs = [
|
|
|
|
installShellFiles
|
|
|
|
];
|
2019-03-26 07:32:21 -07:00
|
|
|
|
2021-02-24 17:10:34 -08:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
astroid
|
|
|
|
isort
|
|
|
|
mccabe
|
|
|
|
toml
|
|
|
|
];
|
2017-09-06 08:28:21 -07:00
|
|
|
|
2021-02-24 17:10:34 -08:00
|
|
|
postInstall = ''
|
|
|
|
mkdir -p $out/share/emacs/site-lisp
|
|
|
|
cp -v "elisp/"*.el $out/share/emacs/site-lisp/
|
|
|
|
installManPage man/*.1
|
2017-09-06 08:28:21 -07:00
|
|
|
'';
|
|
|
|
|
2021-02-24 17:10:34 -08:00
|
|
|
checkInputs = [
|
|
|
|
pytest-benchmark
|
|
|
|
pytest-xdist
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
dontUseSetuptoolsCheck = true;
|
2019-10-17 00:41:52 -07:00
|
|
|
|
2020-06-08 12:42:14 -07:00
|
|
|
# calls executable in one of the tests
|
|
|
|
preCheck = ''
|
|
|
|
export PATH=$PATH:$out/bin
|
|
|
|
'';
|
|
|
|
|
2021-02-24 17:10:34 -08:00
|
|
|
pytestFlagsArray = [
|
|
|
|
"-n auto"
|
|
|
|
];
|
2017-09-06 08:28:21 -07:00
|
|
|
|
2021-02-24 17:10:34 -08:00
|
|
|
disabledTests = lib.optionals stdenv.isDarwin [
|
|
|
|
"test_parallel_execution"
|
|
|
|
"test_py3k_jobs_option"
|
|
|
|
];
|
|
|
|
|
2018-08-30 18:14:41 -07:00
|
|
|
meta = with lib; {
|
2020-09-18 21:20:00 -07:00
|
|
|
homepage = "https://pylint.pycqa.org/";
|
2017-09-06 08:28:21 -07:00
|
|
|
description = "A bug and style checker for Python";
|
|
|
|
license = licenses.gpl1Plus;
|
2021-05-14 07:00:41 -07:00
|
|
|
maintainers = with maintainers; [ ];
|
2017-09-06 08:28:21 -07:00
|
|
|
};
|
|
|
|
}
|