From 23cce978aedc948723a3cce211b4e743b0e7c444 Mon Sep 17 00:00:00 2001 From: Abhishek Koneru Date: Mon, 22 Jul 2013 21:16:59 -0400 Subject: Adding pylint scan to the build. Adding the scripts and the pylintrc file to the build process. The script is called before packaging the classes in the compose scripts. Ticket #316 --- specs/pki-core.spec | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'specs') diff --git a/specs/pki-core.spec b/specs/pki-core.spec index 555f492af..c718b9d62 100644 --- a/specs/pki-core.spec +++ b/specs/pki-core.spec @@ -5,7 +5,7 @@ distutils.sysconfig import get_python_lib; print(get_python_lib(1))")} Name: pki-core Version: 10.1.0 -Release: 0.7%{?dist} +Release: 0.8%{?dist} Summary: Certificate System - PKI Core Components URL: http://pki.fedoraproject.org/ License: GPLv2 @@ -40,6 +40,7 @@ BuildRequires: resteasy-base-jettison-provider BuildRequires: resteasy >= 2.3.2-1 %endif +BuildRequires: pylint BuildRequires: junit BuildRequires: jpackage-utils >= 0:1.7.5-10 %if 0%{?rhel} || 0%{?fedora} >= 19 @@ -526,6 +527,12 @@ cd build cd build %{__make} install DESTDIR=%{buildroot} INSTALL="install -p" +# Scanning the python code with pylint. A return value of 0 represents there are no +# errors or warnings reported by pylint. +sh ../pylint-build-scan.sh %{buildroot} `pwd` +if [ $? -eq 1 ]; then + exit 1 +fi # Fedora 18 and 17: Substitute 'tomcat7jss.jar' for 'tomcatjss.jar' %if ! 0%{?rhel} && 0%{?fedora} <= 18 sed -i -e 's/grant codeBase "file:\/usr\/share\/java\/tomcatjss.jar" {/grant codeBase "file:\/usr\/share\/java\/tomcat7jss.jar" {/' %{buildroot}%{_datadir}/pki/server/conf/pki.policy @@ -1086,6 +1093,9 @@ fi %changelog +* Fri Aug 09 2013 Abhishek Koneru 10.1.0.0.8 +- Added pylint scan to the build process. + * Mon Jul 22 2013 Endi S. Dewata 10.1.0-0.7 - Added man pages for upgrade tools. -- cgit