Merge "deb_dpdk: add new 17.11.x branch"
[ci-management.git] / jjb / csit / include-raw-csit-pylint.sh
index c0cfe6c..2987e5e 100644 (file)
@@ -1,6 +1,17 @@
 #!/bin/bash
 
-sudo apt-get install -y --force-yes pylint
-find resources -name \*.py | xargs pylint --rcfile=pylint.cfg > pylint.log || true
+set -x
+
+# Re-create virtual environment
+rm -rf env || true
+virtualenv env
+. env/bin/activate
+
+# Install requirements, so all CSIT python dependencies are met
+pip install -r requirements.txt
+pip install pylint==1.5.4
+
+# Run pylint, but hide its' return value until python warnings are cleared
+PYTHONPATH=`pwd` pylint --rcfile=pylint.cfg resources/ > pylint.log || true
 
 # vim: ts=4 ts=4 sts=4 et :