Name: pylint Version: 2.1.1 Release: 3 Summary: Python static code analysis tool looking for programming errors License: GPLv2+ URL: http://pylint.pycqa.org Source0: https://github.com/PyCQA/%{name}/archive/%{name}-%{version}.tar.gz Patch0001: pylint-Fix_is_subclass_of_when_one_param_is_not_ClassDef.patch BuildArch: noarch BuildRequires: python3-devel python3-setuptools python3-astroid >= 2.0.2 python3-isort BuildRequires: python3-mccabe python3-pytest python3-pytest-runner Requires: python3-%{name} = %{version}-%{release} %description Pylint is a Python static code analysis tool which looks for programming errors, helps enforcing a coding standard, sniffs for code smells and offers simple refactoring suggestions. It's highly configurable, having special pragmas to control its errors and warnings from within your code, as well as from an extensive configuration file. It is also possible to write your own plugins for adding your own checks or for extending pylint in one way or another. %package -n python3-%{name} Summary: Python static code analysis tool looking for programming errors Requires: python3-astroid >= 2.0.2 python3-setuptools python3-mccabe python3-isort Obsoletes: python3-pylint-gui < 1.7 %python_provide python3-%{name} %description -n python3-%{name} Pylint is a Python static code analysis tool which looks for programming errors, helps enforcing a coding standard, sniffs for code smells and offers simple refactoring suggestions. It's highly configurable, having special pragmas to control its errors and warnings from within your code, as well as from an extensive configuration file. It is also possible to write your own plugins for adding your own checks or for extending pylint in one way or another. %package help Summary: Help documentation of pylint package %description help Help documentation of pylint package. %prep %autosetup -n pylint-%{version} -p1 sed -i 's/\r//g' README.rst %build %py3_build %install %py3_install rm -rf %{buildroot}%{python3_sitelib}/pylint/test install -dm 755 %{buildroot}%{_mandir}/man1 install -pm 644 man/*.1 %{buildroot}%{_mandir}/man1/ for NAME in epylint pylint pyreverse symilar; do mv %{buildroot}%{_bindir}/{$NAME,${NAME}-%{python3_version}} ln -s ${NAME}-%{python3_version} %{buildroot}%{_bindir}/${NAME}-3 mv %{buildroot}%{_mandir}/man1/{${NAME}.1,${NAME}-%{python3_version}.1} ln -s ${NAME}-%{python3_version}.1 %{buildroot}%{_mandir}/man1/${NAME}-3.1 ln -s ${NAME}-%{python3_version} %{buildroot}%{_bindir}/${NAME} ln -s ${NAME}-%{python3_version}.1 %{buildroot}%{_mandir}/man1/${NAME}.1 done %check export PYTHONPATH=%{buildroot}%{python3_sitelib} %{__python3} bin/pylint -rn --rcfile=pylintrc --load-plugins=pylint.extensions.docparams, pylint.extensions.mccabe pylint || : %{__python3} -m pytest -v -k "not (test_functional or test_good_comprehension_checks)" %files %doc README.rst ChangeLog examples elisp COPYING %{_bindir}/{epylint,pylint,pyreverse,symilar} %files -n python3-%{name} %doc COPYING %{python3_sitelib}/pylint* %{_bindir}/{*-3,*-%{python3_version}} %files help %{_mandir}/man1/* %changelog * Mon Feb 17 2020 daiqianwen - 2.1.1-3 - package init