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