Configure the agent path for the different settings files.

This commit is contained in:
Manuele Simi 2019-05-30 22:11:17 +02:00
parent 8b91d4900a
commit be1627d1b4
1 changed files with 4 additions and 8 deletions

12
Jenkinsfile vendored
View File

@ -8,29 +8,25 @@ if (params.Type == 'SNAPSHOT-DRY-RUN') {
echo "Configure Maven for SNAPSHOT-DRY-RUN artifacts"
options = ''
maven_local_repo_path = "${agent_root_folder}/local-snapshots"
maven_settings_file = "${env.HOME}/.m2/jenkins-shapshots-dry-run-settings.xml"
maven_settings_file = "${env.HOME}/.m2/settings.xml" //TODO: to remove, just for testing
maven_settings_file = "${agent_root_folder}/.m2/jenkins-shapshots-dry-run-settings.xml"
}
if (params.Type == 'SNAPSHOT') {
echo "Configure Maven for SNAPSHOT artifacts"
options = ''
maven_local_repo_path = "${agent_root_folder}/local-snapshots"
maven_settings_file = "${env.HOME}/.m2/jenkins-shapshots-settings.xml"
maven_settings_file = "${env.HOME}/.m2/settings.xml" //TODO: to remove, just for testing
maven_settings_file = "${agent_root_folder}/.m2/jenkins-shapshots-settings.xml"
}
if (params.Type == 'RELEASE-DRY-RUN') {
echo "Configure Maven for RELEASE-DRY-RUN artifacts"
options = ''
maven_local_repo_path = "${agent_root_folder}/local-releases"
maven_settings_file = "${env.HOME}/.m2/jenkins-releases-dry-run-settings.xml"
maven_settings_file = "${env.HOME}/.m2/settings.xml" //TODO: to remove, just for testing
maven_settings_file = "${agent_root_folder}/.m2/jenkins-releases-dry-run-settings.xml"
}
if (params.Type == 'RELEASE') {
echo "Configure Maven for RELEASE artifacts"
options = ''
maven_local_repo_path = "${agent_root_folder}/local-releases"
maven_settings_file = "${env.HOME}/.m2/jenkins-releases-settings.xml"
maven_settings_file = "${env.HOME}/.m2/settings.xml" //TODO: to remove, just for testing
maven_settings_file = "${agent_root_folder}/.m2/jenkins-releases-settings.xml"
}
echo "Use settings file at ${maven_settings_file}"
echo "Use local repo at ${maven_local_repo_path}"