JAL-3210 create a site.tar.gz. Some improvement to eclipse-workspace handling
authorsoares <bsoares@dundee.ac.uk>
Fri, 30 Aug 2019 11:14:26 +0000 (12:14 +0100)
committersoares <bsoares@dundee.ac.uk>
Fri, 30 Aug 2019 11:14:26 +0000 (12:14 +0100)
.gitignore
build.gradle
gradle.properties

index e450e6b..e9065ca 100644 (file)
@@ -10,3 +10,6 @@
 /site
 /site2
 /template.html
+*.swp
+/build
+/classes
index fc183a5..351d9ac 100644 (file)
@@ -284,10 +284,10 @@ def tempEclipseWorkspace = ""
 
 task jalviewjsSetTempEclipseWorkspace {
   tempEclipseWorkspace = file(jalviewjs_eclipse_workspace)
-  if (!tempEclipseWorkspace.exists()) {
+  if (!tempEclipseWorkspace.exists() && jalviewjs_eclipse_workspace.startsWith(File.separator)) {
     tempEclipseWorkspace = File.createTempDir()
     print("ECLIPSE WORKSPACE: "+tempEclipseWorkspace.getPath())
-    //tempEclipseWorkspace.deleteOnExit()
+    tempEclipseWorkspace.deleteOnExit()
   }
 }
 
@@ -371,7 +371,25 @@ task jalviewjsBuildSite {
   dependsOn jalviewjsTranspile
 }
 
+task jalviewjsSiteTar(type: Tar) {
+  dependsOn jalviewjsBuildSite
+  def outputFilename = "site.tar.gz"
+  try {
+    archiveFileName = outputFilename
+  } catch (Exception e) {
+    archiveName = outputFilename
+  }
+
+  compression Compression.GZIP
+
+  from jalviewjs_site_dir
+  into jalviewjs_site_dir
+
+  inputs.dir(jalviewjs_site_dir)
+}
+
 task jalviewjs {
   dependsOn jalviewjsCreateJ2sSettings 
   dependsOn jalviewjsBuildSite
 }
+
index 3bc9e0a..1fa2f14 100644 (file)
@@ -1,7 +1,7 @@
 jalviewDir = .
 
-JAVA_VERSION = 1.8
-#JAVA_VERSION = 11
+#JAVA_VERSION = 1.8
+JAVA_VERSION = 11
 JALVIEW_VERSION = DEVELOPMENT
 INSTALLATION = Source
 
@@ -34,8 +34,8 @@ j11libDir = j11lib
 
 dev = false
 
-jalviewjs_eclipse_root = /Users/bsoares/buildtools/eclipse/eclipse-jee-2019-06/Eclipse.app
-#jalviewjs_eclipse_root = /home/bsoares/buildtools/eclipse/eclipse-jee-2019-06
+#jalviewjs_eclipse_root = /Users/bsoares/buildtools/eclipse/eclipse-jee-2019-06/Eclipse.app
+jalviewjs_eclipse_root = /home/bsoares/buildtools/eclipse/eclipse-jee-2019-06
 
 jalviewjs_utils_dir = utils/jalviewjs
 jalviewjs_eclipse_plugins_dir = eclipse/plugins
@@ -48,7 +48,7 @@ jalviewjs_site_dir = site
 jalviewjs_j2s_subdir = swingjs/j2s
 jalviewjs_j2s_settings_file = dot_j2s
 jalviewjs_j2s_settings = .j2s
-jalviewjs_eclipse_workspace = /tmp/eclipse-workspace
+jalviewjs_eclipse_workspace = ../tmp/eclipse-workspace
 jalviewjs_eclipseBuildArg = build
 #jalviewjs_eclipseBuildArg = cleanBuild