JAL-3246 add -Pgetdown_local=true to use local files
authorBen Soares <bsoares@dundee.ac.uk>
Wed, 8 May 2019 17:25:06 +0000 (18:25 +0100)
committerBen Soares <bsoares@dundee.ac.uk>
Wed, 8 May 2019 17:25:06 +0000 (18:25 +0100)
build.gradle
getdown/lib/commons-compress-1.18.jar [deleted file]
gradle.properties
utils/dev_macos_install.sh

index 0088845..d81604e 100644 (file)
@@ -55,7 +55,6 @@ ext {
   getdownResourceDir = getdownWebsiteDir + '/' + getdown_resource_dir
   getdownLauncher = jalviewDir + '/' + getdown_launcher
   getdownFilesDir = jalviewDir + '/' + getdown_files_dir + '/' + JAVA_VERSION + '/'
-  getdownLib1 = jalviewDir + '/' + getdown_lib1
   def getdownChannel = getdown_channel_name
   if (getdown_channel_name.equals("COMMIT")) {
     getdownChannel = getGitHash()
@@ -648,6 +647,9 @@ task getdownWebsite() {
     props.put("getdown_txt_java_min_version", getdown_alt_java_min_version)
     props.put("getdown_txt_multi_java_location", getdown_alt_multi_java_location)
 
+    if (getdown_local == "true") {
+      getdown_app_base = "file://"+file(getdownWebsiteDir).getAbsolutePath()
+    }
     props.put("getdown_txt_appbase", getdown_app_base)
     props.each{ prop, val ->
       if (prop.startsWith("getdown_txt_") && val != null) {
@@ -747,11 +749,6 @@ task getdownWebsite() {
     }
 
     copy {
-      from getdownLib1
-      into project.ext.getdownFilesDir + '/' + packageDir
-    }
-
-    copy {
       from jalviewDir + '/' + project.getProperty('getdown_txt_ui.background_image')
       from jalviewDir + '/' + project.getProperty('getdown_txt_ui.error_background')
       from jalviewDir + '/' + project.getProperty('getdown_txt_ui.progress_image')
@@ -770,8 +767,7 @@ task getdownDigest(type: JavaExec) {
   group = "distribution"
   description = "Digest the getdown website folder"
   dependsOn getdownWebsite
-  classpath = files(jalviewDir + '/' + getdown_core)
-  classpath file(jalviewDir + '/' + getdown_lib1)
+  classpath = files(jalviewDir + '/' + getdown_core, jalviewDir+'/'+getdown_launcher)
   main = "com.threerings.getdown.tools.Digester"
   args project.ext.getdownWebsiteDir
   inputs.dir(project.ext.getdownWebsiteDir)
diff --git a/getdown/lib/commons-compress-1.18.jar b/getdown/lib/commons-compress-1.18.jar
deleted file mode 100644 (file)
index e401046..0000000
Binary files a/getdown/lib/commons-compress-1.18.jar and /dev/null differ
index 8143d44..49ace5f 100644 (file)
@@ -46,6 +46,7 @@ launcherClass = jalview.bin.Jalview
 
 gradlePluginsDir = gradle/plugins
 
+getdown_local = false
 getdown_website_dir = getdown/website
 getdown_resource_dir = resource
 getdown_app_dir = dist
@@ -53,7 +54,6 @@ getdown_j11lib_dir = j11lib
 getdown_files_dir = getdown/files
 getdown_launcher = getdown/lib/getdown-launcher.jar
 getdown_core = getdown/lib/getdown-core-1.8.3-SNAPSHOT.jar
-getdown_lib1 = getdown/lib/commons-compress-1.18.jar
 getdown_base_txt = getdown/files/getdown.txt
 getdown_txt_title = Jalview
 getdown_channel_base = http://www.jalview.org/getdown/jalview
index c9e219f..61155c2 100755 (executable)
@@ -8,7 +8,7 @@ APPLICATIONS=/Applications
 CHANNEL=NOCHANNEL
 DMG=build/install4j/11/Jalview-OFFLINE_macos-app_DEVELOPMENT-j11.dmg
 
-gradle installers -Pgetdown_channel_name=NOCHANNEL -Pinstall4jMediaTypes=macosArchive
+gradle installers -Pgetdown_channel_name=NOCHANNEL -Pinstall4jMediaTypes=macosArchive -Pgetdown_local=true
 
 if [ $? = 0 ]; then
   umount "/Volumes/$INSTALLERVOL"