changes in file

This commit is contained in:
shikhar.s 2019-08-13 15:58:05 +05:30
parent 6d505f5a74
commit afa4f515d3

84
Jenkinsfile vendored
View File

@ -43,36 +43,36 @@ pipeline {
} }
stage ('Check_style') { // stage ('Check_style') {
steps { // steps {
sh """ // sh """
if [ ! -d venv ] ; then // if [ ! -d venv ] ; then
virtualenv --python=python2.7 venv // virtualenv --python=python2.7 venv
fi // fi
source venv/bin/activate // source venv/bin/activate
export PYTHONPATH="$PWD:$PYTHONPATH" // export PYTHONPATH="$PWD:$PYTHONPATH"
pip install pylint // pip install pylint
cd repo // cd repo
### 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) MYMODULE/ > pylint.log || exit 0 // pylint --rcfile=pylint.cfg $(find . -maxdepth 1 -name "*.py" -print) MYMODULE/ > pylint.log || exit 0
""" // """
step([$class: 'WarningsPublisher', // step([$class: 'WarningsPublisher',
parserConfigurations: [ // parserConfigurations: [
[ // [
parserName: 'pylint', // parserName: 'pylint',
pattern: 'report/pylint.log' // pattern: 'report/pylint.log'
]], // ]],
unstableTotalAll: '0', // unstableTotalAll: '0',
usePreviousBuildAsReference: true // usePreviousBuildAsReference: true
]) // ])
} // }
} // }
stage('Test environment') { stage('Test environment') {
steps { steps {
@ -89,26 +89,26 @@ 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 // #. venv/bin/activate
export PATH=${VIRTUAL_ENV}/bin:${PATH} // export PATH=${VIRTUAL_ENV}/bin:${PATH}
pip install pylint // pip install pylint
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') {