From 699fe86b373eb59aa5e082ccfe313994204c8e34 Mon Sep 17 00:00:00 2001 From: Ben Soares Date: Wed, 19 Feb 2020 16:37:47 +0000 Subject: [PATCH] JAL-3289 Improved the name of the channel_launch.jvl file to channel_launch-CHANNELNAMEWITHPLANKEY.jvl --- build.gradle | 12 ++++++++---- gradle.properties | 2 +- utils/install4j/install4j8_template.install4j | 2 +- 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/build.gradle b/build.gradle index 27e040c..9dae53a 100644 --- a/build.gradle +++ b/build.gradle @@ -126,6 +126,7 @@ ext { getdownAppDistDir = getdown_app_dir_alt buildProperties = string("${classesDir}/${build_properties_file}") reportRsyncCmd = false + jvlChannelName = CHANNEL.toLowerCase() switch (CHANNEL) { case "BUILD": @@ -133,6 +134,7 @@ ext { getdown_channel_base = bamboo_channelbase getdownChannelName = string("${bamboo_planKey}/${JAVA_VERSION}") getdownAppBase = string("${bamboo_channelbase}/${bamboo_planKey}${bamboo_getdown_channel_suffix}/${JAVA_VERSION}") + jvlChannelName += "_${getdownChannelName}" break case "RELEASE": @@ -208,6 +210,8 @@ ext { getdownAppBase = string(getProperty("getdown_appbase_override")) println("Overriding getdown appbase with '${getdownAppBase}'") } + // sanitise file name for jalview launcher file for this channel + jvlChannelName = jvlChannelName.replaceAll(/[^\w\-]/,"_") getdownAppDir = string("${getdownWebsiteDir}/${getdownAppDistDir}") //getdownJ11libDir = "${getdownWebsiteDir}/${getdown_j11lib_dir}" @@ -1096,9 +1100,9 @@ task getdownWebsite() { def getdown_txt = file("${getdownWebsiteDir}/getdown.txt") getdown_txt.write(getdownTextString) - def getdownLaunchJvl = ( (getdownChannelName != null && getdownChannelName.length() > 0)?"${getdownChannelName}_":"" ) + getdown_launch_jvl - def launch_jvl = file("${getdownWebsiteDir}/${getdown_launch_jvl}") - launch_jvl.write("appbase="+props.get("getdown_txt_appbase")) + def getdownLaunchJvl = getdown_launch_jvl_name + ( (jvlChannelName != null && jvlChannelName.length() > 0)?"-${jvlChannelName}":"" ) + ".jvl" + def launchJvl = file("${getdownWebsiteDir}/${getdownLaunchJvl}") + launchJvl.write("appbase="+props.get("getdown_txt_appbase")) copy { from getdownLauncher @@ -1133,7 +1137,7 @@ task getdownWebsite() { copy { from getdown_txt - from launch_jvl + from launchJvl from getdownLauncher from "${getdownWebsiteDir}/${getdown_build_properties}" if (file(getdownLauncher).getName() != getdown_launcher) { diff --git a/gradle.properties b/gradle.properties index c1aece3..7a51138 100644 --- a/gradle.properties +++ b/gradle.properties @@ -61,8 +61,8 @@ getdown_launcher = getdown-launcher.jar getdown_launcher_local = getdown-launcher-local.jar getdown_launcher_new = getdown-launcher-new.jar getdown_core = getdown/lib/getdown-core.jar -getdown_launch_jvl = channel_launch.jvl getdown_build_properties = build_properties +getdown_launch_jvl_name = channel_launch getdown_txt_allow_offline = true getdown_txt_max_concurrent_downloads = 10 # now got better defaults when not set diff --git a/utils/install4j/install4j8_template.install4j b/utils/install4j/install4j8_template.install4j index f7cab3d..4f37185 100644 --- a/utils/install4j/install4j8_template.install4j +++ b/utils/install4j/install4j8_template.install4j @@ -749,7 +749,7 @@ return console.askYesNo(message, true); - channel_launch.jvl + channel_launch*.jvl -- 1.7.10.2