Output ${AGENT_ROOT_FOLDER}/build_commits.txt.

This commit is contained in:
Manuele Simi 2019-10-21 21:28:21 -04:00
parent 11369aa31f
commit 146303c77f
1 changed files with 2 additions and 0 deletions

2
Jenkinsfile vendored
View File

@ -120,6 +120,7 @@ pipeline {
mv "${AGENT_ROOT_FOLDER}/settings.xml" "${AGENT_ROOT_FOLDER}/settings.${PIPELINE_BUILD_NUMBER}" mv "${AGENT_ROOT_FOLDER}/settings.xml" "${AGENT_ROOT_FOLDER}/settings.${PIPELINE_BUILD_NUMBER}"
cp "${AGENT_ROOT_FOLDER}/${MAVEN_SETTINGS_FILE}" "${AGENT_ROOT_FOLDER}/settings.xml" cp "${AGENT_ROOT_FOLDER}/${MAVEN_SETTINGS_FILE}" "${AGENT_ROOT_FOLDER}/settings.xml"
echo "Done with local repository and settings" echo "Done with local repository and settings"
cat "Build #${PIPELINE_BUILD_NUMBER}" > ${AGENT_ROOT_FOLDER}/build_commits.txt
''' '''
} }
} }
@ -242,6 +243,7 @@ pipeline {
script { script {
sh ''' sh '''
mv "${AGENT_ROOT_FOLDER}/settings.${PIPELINE_BUILD_NUMBER}" "${AGENT_ROOT_FOLDER}/settings.xml" mv "${AGENT_ROOT_FOLDER}/settings.${PIPELINE_BUILD_NUMBER}" "${AGENT_ROOT_FOLDER}/settings.xml"
mv ${AGENT_ROOT_FOLDER}/build_commits.txt ${AGENT_ROOT_FOLDER}/build_commits.${PIPELINE_BUILD_NUMBER}
''' '''
} }
echo 'The default maven settings have been restored' echo 'The default maven settings have been restored'