Reset jenkinsfile to last working version
Project: http://git-wip-us.apache.org/repos/asf/logging-log4net/repo Commit: http://git-wip-us.apache.org/repos/asf/logging-log4net/commit/ef304c39 Tree: http://git-wip-us.apache.org/repos/asf/logging-log4net/tree/ef304c39 Diff: http://git-wip-us.apache.org/repos/asf/logging-log4net/diff/ef304c39 Branch: refs/heads/master Commit: ef304c39039a78209bef27546eedcedd65375b99 Parents: b08bb61 Author: Dominik Psenner <[email protected]> Authored: Sat Jul 1 03:16:45 2017 +0200 Committer: Dominik Psenner <[email protected]> Committed: Sat Jul 1 03:16:45 2017 +0200 ---------------------------------------------------------------------- Jenkinsfile | 68 +++++++++++++++++++------------------------------------- 1 file changed, 23 insertions(+), 45 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/logging-log4net/blob/ef304c39/Jenkinsfile ---------------------------------------------------------------------- diff --git a/Jenkinsfile b/Jenkinsfile index c0d3848..60577e5 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -17,52 +17,30 @@ * under the License. */ -pipeline { - options { - timeout(time: 1, unit: 'HOURS') - } - agent { label 'Windows' } - environment { - // TODO: find a better way to determine nant latest - NAnt = 'F:\\jenkins\\tools\\nant\\nant-0.92\\bin\\NAnt.exe' - } - node { - stages { - stage('Checkout') { - steps { - checkout scm - } - } - stage('Build') { - steps { - bat "${NAnt} -buildfile:log4net.build" - } - } - stage('Test on Windows') { - steps { - bat "${NAnt} -buildfile:tests\\nant.build" - } - } - stage('Build-Site') { - steps { - bat "${NAnt} -buildfile:log4net.build generate-site" - } - } - stage('Deploy-Site') { - when { - branch 'master' - } - steps { - echo 'This is a placeholder for the deployment of the site' - } - } +node('Windows') +{ + // TODO: find a better way to determine nant latest + def NANT_LATEST="F:\\jenkins\\tools\\nant\\nant-0.92\\bin" + dir('build') + { + stage('Checkout') + { + checkout scm } - } - post { - failure { - echo 'Failed build' - // TODO: send email as soon as the entire building is more stable - //step([$class: 'Mailer', notifyEveryUnstableBuild: true, recipients: '[email protected]']) + + stage('Build') + { + withEnv(["Path+NANT=$NANT_LATEST"]) + { + bat "NAnt.exe -buildfile:log4net.build" + } + } + stage('Test') + { + withEnv(["Path+NANT=$NANT_LATEST"]) + { + bat "NAnt.exe -buildfile:tests\\nant.build" + } } } }
