From: Charles Ofoegbu Date: Wed, 19 Nov 2014 11:11:41 +0000 (+0000) Subject: JAL-1522 included installation details in log output X-Git-Tag: Jalview_2_9~141^2~2^2 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=7fb90059bba45e0ed35a9c78f440bd7d1563073f;p=jalview.git JAL-1522 included installation details in log output --- diff --git a/build.xml b/build.xml index 19b41e5..d8ebe1e 100755 --- a/build.xml +++ b/build.xml @@ -62,8 +62,12 @@ --> + + + + @@ -175,8 +179,9 @@
---Jalview Build Details--- -
+ +
diff --git a/src/jalview/bin/JalviewLite.java b/src/jalview/bin/JalviewLite.java index 0abd31b..ae8bc98 100644 --- a/src/jalview/bin/JalviewLite.java +++ b/src/jalview/bin/JalviewLite.java @@ -1269,7 +1269,7 @@ public class JalviewLite extends Applet implements public static boolean debug = false; - static String builddate = null, version = null; + static String builddate = null, version = null, installation = null; private static void initBuildDetails() { @@ -1277,6 +1277,7 @@ public class JalviewLite extends Applet implements { builddate = "unknown"; version = "test"; + installation = "Webstart"; java.net.URL url = JalviewLite.class .getResource("/.build_properties"); if (url != null) @@ -1296,6 +1297,10 @@ public class JalviewLite extends Applet implements { builddate = line.substring(line.indexOf("=") + 1); } + if (line.indexOf("INSTALLATION") > -1) + { + installation = line.substring(line.indexOf("=") + 1); + } } } catch (Exception ex) { @@ -1311,6 +1316,12 @@ public class JalviewLite extends Applet implements return builddate; } + public static String getInstallation() + { + initBuildDetails(); + return installation; + } + public static String getVersion() { initBuildDetails(); @@ -1360,6 +1371,7 @@ public class JalviewLite extends Applet implements System.err.println("JalviewLite Version " + getVersion()); System.err.println("Build Date : " + getBuildDate()); + System.err.println("Installation : " + getInstallation()); } String externalsviewer = getParameter("externalstructureviewer"); diff --git a/src/jalview/gui/Desktop.java b/src/jalview/gui/Desktop.java index 23ba893..19dbcdb 100644 --- a/src/jalview/gui/Desktop.java +++ b/src/jalview/gui/Desktop.java @@ -323,8 +323,11 @@ public class Desktop extends jalview.jbgui.GDesktop implements } jconsole = new Console(this, showjconsole); // add essential build information - jconsole.setHeader("Jalview Desktop " + jconsole.setHeader("Jalview Version: " + jalview.bin.Cache.getProperty("VERSION") + "\n" + + "Jalview Installation: " + + jalview.bin.Cache.getDefault("INSTALLATION", "unknown") + + "\n" + "Build Date: " + jalview.bin.Cache.getDefault("BUILD_DATE", "unknown") + "\n" + "Java version: " + System.getProperty("java.version") + "\n"