add of pylint check2

This commit is contained in:
shikhar.s 2019-07-06 18:27:36 +05:30
parent ccb4775991
commit 8f6cad8b12

40
Jenkinsfile vendored
View File

@ -29,7 +29,7 @@ pipeline {
[ -d venv ] && rm -rf venv [ -d venv ] && rm -rf venv
#virtualenv --python=python2.7 venv #virtualenv --python=python2.7 venv
virtualenv venv virtualenv venv
#. venv/bin/activate source venv/bin/activate
export PATH=${VIRTUAL_ENV}/bin:${PATH} export PATH=${VIRTUAL_ENV}/bin:${PATH}
pip install --upgrade pip pip install --upgrade pip
pip install -r requirements.txt -r dev-requirements.txt pip install -r requirements.txt -r dev-requirements.txt
@ -77,7 +77,7 @@ pipeline {
[ -d venv ] && rm -rf venv [ -d venv ] && rm -rf venv
#virtualenv --python=python2.7 venv #virtualenv --python=python2.7 venv
virtualenv venv virtualenv venv
#. venv/bin/activate source venv/bin/activate
export PATH=${VIRTUAL_ENV}/bin:${PATH} export PATH=${VIRTUAL_ENV}/bin:${PATH}
python setup.py install python setup.py install
sudo /home/cis/.local/bin/nosetests --with-xunit tests sudo /home/cis/.local/bin/nosetests --with-xunit tests
@ -85,27 +85,27 @@ pipeline {
} }
} }
stage('Pylint Checker') { // stage('Pylint Checker') {
steps { // steps {
sh ''' // sh '''
echo ${SHELL} // echo ${SHELL}
[ -d venv ] && rm -rf venv // [ -d venv ] && rm -rf venv
#virtualenv --python=python2.7 venv // #virtualenv --python=python2.7 venv
virtualenv venv // virtualenv venv
#. venv/bin/activate // source venv/bin/activate
export PATH=${VIRTUAL_ENV}/bin:${PATH} // export PATH=${VIRTUAL_ENV}/bin:${PATH}
pip install pylint // pip install pylint
echo ${pwd} // echo ${pwd}
### Need this because some strange control sequences when using default TERM=xterm // ### Need this because some strange control sequences when using default TERM=xterm
export TERM="linux" // export TERM="linux"
## || exit 0 because pylint only exits with 0 if everything is correct // ## || exit 0 because pylint only exits with 0 if everything is correct
pylint --rcfile=pylint.cfg $(find . -maxdepth 1 -name "*.py" -print) Pybitmessage/ > pylint.log || exit 0 // pylint --rcfile=pylint.cfg $(find . -maxdepth 1 -name "*.py" -print) Pybitmessage/ > pylint.log || exit 0
''' // '''
} // }
} // }
stage('Test Run') { stage('Test Run') {