Merge branch 'GP-0_ryanmkurtz_PR-5522_jobermayr_assembleAll'

This commit is contained in:
Ryan Kurtz 2023-09-11 12:31:47 -04:00
commit cb3e8062f6

View File

@ -482,40 +482,25 @@ def updateSlaFilesTimestamp(String distributionDirectoryPath, int timeOffsetMinu
} }
/********************************************************************************* /*********************************************************************************
* *
* Creates the local installation zip. * Assemble all targets.
* *
**********************************************************************************/ **********************************************************************************/
task createInstallationZip(type: Zip) { t -> task assembleAll() {
group 'private' group 'private'
description "Creates local installation zip (does not clean up artifacts) [gradle/root/distribution.gradle]" description "Assembles all targets to one installation directory (does not clean up artifacts) [gradle/root/distribution.gradle]"
dependsOn assembleDistribution dependsOn assembleDistribution
dependsOn assembleSource dependsOn assembleSource
dependsOn "assembleDistribution_$currentPlatform" dependsOn "assembleDistribution_$currentPlatform"
if (project.hasProperty("allPlatforms")) { if (project.hasProperty("allPlatforms")) {
project.PLATFORMS.each { platform -> project.PLATFORMS.each { platform ->
dependsOn ":assembleDistribution_${platform.name}" dependsOn ":assembleDistribution_${platform.name}"
} }
} }
if (project.hasProperty("allPlatforms")) {
archiveFileName = "${ZIP_NAME_PREFIX}.zip"
}
else {
archiveFileName = "${ZIP_NAME_PREFIX}_${currentPlatform}.zip"
}
destinationDirectory = DISTRIBUTION_DIR
// Make sure that we don't try to copy the same file with the same path.
duplicatesStrategy 'exclude'
from (DISTRIBUTION_DIR.getPath() + "/" + ZIP_DIR_PREFIX) {
into ZIP_DIR_PREFIX
}
doFirst { doFirst {
// We always want the extensions directory to exist in the zip, even if there's nothing // We always want the extensions directory to exist in the zip, even if there's nothing
// installed there. // installed there.
@ -530,6 +515,34 @@ task createInstallationZip(type: Zip) { t ->
// two minutes. // two minutes.
updateSlaFilesTimestamp(DISTRIBUTION_DIR.getPath(), 2) updateSlaFilesTimestamp(DISTRIBUTION_DIR.getPath(), 2)
} }
}
/*********************************************************************************
*
* Creates the local installation zip.
*
**********************************************************************************/
task createInstallationZip(type: Zip) { t ->
group 'private'
description "Creates local installation zip (does not clean up artifacts) [gradle/root/distribution.gradle]"
dependsOn assembleAll
if (project.hasProperty("allPlatforms")) {
archiveFileName = "${ZIP_NAME_PREFIX}.zip"
}
else {
archiveFileName = "${ZIP_NAME_PREFIX}_${currentPlatform}.zip"
}
destinationDirectory = DISTRIBUTION_DIR
// Make sure that we don't try to copy the same file with the same path.
duplicatesStrategy 'exclude'
from (DISTRIBUTION_DIR.getPath() + "/" + ZIP_DIR_PREFIX) {
into ZIP_DIR_PREFIX
}
doLast { doLast {
delete file(DISTRIBUTION_DIR.getPath() + "/" + ZIP_DIR_PREFIX) delete file(DISTRIBUTION_DIR.getPath() + "/" + ZIP_DIR_PREFIX)