From: Ben Soares Date: Thu, 27 Jun 2024 16:46:47 +0000 (+0100) Subject: JAL-3631 Log4j logging to .jalview.log file when requested. Clean(ish) handover of... X-Git-Tag: Release_2_11_4_0~24^2~14 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=19ed57b4dea47513cf3fb02bde8ef7857632898e;p=jalview.git JAL-3631 Log4j logging to .jalview.log file when requested. Clean(ish) handover of log file from getdown to jalview. --- diff --git a/getdown/lib/getdown-core.jar b/getdown/lib/getdown-core.jar index 191df35..5ed4dc9 100644 Binary files a/getdown/lib/getdown-core.jar and b/getdown/lib/getdown-core.jar differ diff --git a/getdown/lib/getdown-launcher-local.jar b/getdown/lib/getdown-launcher-local.jar index 7f40797..8e35fd0 100644 Binary files a/getdown/lib/getdown-launcher-local.jar and b/getdown/lib/getdown-launcher-local.jar differ diff --git a/getdown/lib/getdown-launcher.jar b/getdown/lib/getdown-launcher.jar index bb2bf61..daf333e 100644 Binary files a/getdown/lib/getdown-launcher.jar and b/getdown/lib/getdown-launcher.jar differ diff --git a/getdown/src/getdown/core/src/main/java/com/threerings/getdown/data/Application.java b/getdown/src/getdown/core/src/main/java/com/threerings/getdown/data/Application.java index d210044..8db0983 100644 --- a/getdown/src/getdown/core/src/main/java/com/threerings/getdown/data/Application.java +++ b/getdown/src/getdown/core/src/main/java/com/threerings/getdown/data/Application.java @@ -1092,21 +1092,14 @@ public class Application args.add("-Dlauncher.appbase=" + getAppbase().toString()); args.add("-Dlauncher.appdir=" + getAppDir()); args.add("-Dlauncher.version=" + Build.version()); - if (System.getProperty("installer.appdir") != null) { - args.add("-Dinstaller.appdir=" + System.getProperty("installer.appdir")); - } + addSystemPropertyIfNotNull(args, "installer.appdir"); // add the marker indicating the app is running in getdown args.add("-D" + Properties.GETDOWN + "=true"); args.add("-Dsys.install4jVersion=" + Application.i4jVersion); - if (System.getProperty("installer.template_version") != null) { - args.add("-Dinstaller.template_version=" + System.getProperty("installer.template_version")); - } - if (System.getProperty("installer.logfile") != null) { - args.add("-Dinstaller.logfile=" + System.getProperty("installer.logfile")); - } - if (System.getProperty("installer.extrainfo") != null) { - args.add("-Dinstaller.extrainfo=" + System.getProperty("installer.extrainfo")); - } + addSystemPropertyIfNotNull(args, "installer.template_version"); + addSystemPropertyIfNotNull(args, "installer.logfile"); + addSystemPropertyIfNotNull(args, "installer.logfile_append"); + addSystemPropertyIfNotNull(args, "installer.extrainfo"); // backward compatibility (old getdown-launcher.jar) args.add("-Dgetdownappdir=" + getAppDir()); @@ -1141,18 +1134,6 @@ public class Application if (! StringUtil.isBlank(_jalviewUri)) { _appargs.add(0, _jalviewUri); } - /* don't convert jalviewX:// URIs to https:// URLs as Jalview can now do that - if (_appargs.size() > 0) { - String jalviewUri = _appargs.get(0); - log.info("Trying to parse uri '"+jalviewUri+"'"); - if (HttpUtils.isJalviewSchemeUri(jalviewUri)) { - String jalviewUrl = HttpUtils.equivalentJalviewUrl(jalviewUri); - log.info("Turned url '"+jalviewUri+"' into '"+jalviewUrl+"'"); - _appargs.clear(); - _appargs.add(jalviewUrl); - } - } - */ for (String argString: _appargs) { if (argString.startsWith("-jvmmempc=")) { @@ -1250,7 +1231,7 @@ public class Application String[] envp = createEnvironment(); String[] sargs = args.toArray(new String[args.size()]); - log.info("Running " + StringUtil.join(sargs, "\n ")); + log.info("Running \"" + StringUtil.join(sargs, "\" \\\n \"") + "\""); // don't set the working dir, leave it the same as the working dir of the invocation //return Runtime.getRuntime().exec(sargs, envp, getAppDir()); @@ -2215,6 +2196,17 @@ public class Application } } + private static void addSystemPropertyIfNotNull(List args, String key) { + if (args == null || key == null || System.getProperty(key) == null) { + return; + } + StringBuilder sb = new StringBuilder("-D"); + sb.append(key); + sb.append("="); + sb.append(System.getProperty(key)); + args.add(sb.toString()); + } + protected final EnvConfig _envc; protected File _config; protected File _backupConfig; diff --git a/getdown/src/getdown/launcher/src/main/java/com/threerings/getdown/launcher/Getdown.java b/getdown/src/getdown/launcher/src/main/java/com/threerings/getdown/launcher/Getdown.java index aeb2dbd..fcd6dce 100644 --- a/getdown/src/getdown/launcher/src/main/java/com/threerings/getdown/launcher/Getdown.java +++ b/getdown/src/getdown/launcher/src/main/java/com/threerings/getdown/launcher/Getdown.java @@ -1065,17 +1065,18 @@ public abstract class Getdown extends Thread BufferedReader reader = new BufferedReader(new InputStreamReader(in)); String line; while ((line = reader.readLine()) != null) { - if (!_closed) { - out.println(line); - out.flush(); - } // look for logfile handover - if (line.equals(LaunchUtils.LOGFILE_HANDOVER)) { + if (line.endsWith(LaunchUtils.LOGFILE_HANDOVER)) { + out.println("LAUNCHER end of logging"); out.flush(); out.close(); _closed = true; } - // check for desktop creation line and end early + if (!_closed) { + out.println("LAUNCHER pass-through: "+line); + out.flush(); + } + // check for desktop creation line and close splashscreen early if (!_disposed && line.endsWith(": CREATED DESKTOP")) { // pump the percent up to 100% if (_latestInstance != null) { diff --git a/getdown/src/getdown/launcher/src/main/java/com/threerings/getdown/launcher/GetdownApp.java b/getdown/src/getdown/launcher/src/main/java/com/threerings/getdown/launcher/GetdownApp.java index 71a0402..6800f5a 100644 --- a/getdown/src/getdown/launcher/src/main/java/com/threerings/getdown/launcher/GetdownApp.java +++ b/getdown/src/getdown/launcher/src/main/java/com/threerings/getdown/launcher/GetdownApp.java @@ -64,7 +64,8 @@ public class GetdownApp */ public static Getdown start (String[] argv) throws Exception { jalview.util.ErrorLog.setHasConsole(false); - jalview.util.ErrorLog.setPrefix("LAUNCHER - "); + jalview.util.ErrorLog.setPrefix("LAUNCHER: "); + jalview.util.ErrorLog.outPrintln("start of logging"); List notes = new ArrayList<>(); boolean append = false; EnvConfig envc = EnvConfig.create(argv, notes, GetdownApp.class); @@ -88,17 +89,16 @@ public class GetdownApp logFileName = System.getProperty("user.home") + File.separator + logFileName.substring(2); } logFile = new File(logFileName); - append = true; + append = Boolean.parseBoolean(System.getProperty("installer.logfile_append")); } else { logFile = new File(envc.appDir, "launcher.log"); } try { PrintStream logOut = new PrintStream( new BufferedOutputStream(new FileOutputStream(logFile, append)), true); + System.setOut(logOut); System.setErr(logOut); - log.info(Note.info("LAUNCHER starting to log")); - log.info(Note.info("Launcher logging to '" + logFile.getAbsolutePath() + "'")); } catch (IOException ioe) { log.warning("Unable to redirect output to '" + logFile + "': " + ioe); } @@ -131,7 +131,7 @@ public class GetdownApp } // record a few things for posterity - log.info("------------------ VM Info ------------------"); + log.info("------------- Launcher VM Info --------------"); log.info("-- OS Name: " + System.getProperty("os.name")); log.info("-- OS Arch: " + System.getProperty("os.arch")); log.info("-- OS Vers: " + System.getProperty("os.version")); diff --git a/j11lib/getdown-core.jar b/j11lib/getdown-core.jar index 191df35..5ed4dc9 100644 Binary files a/j11lib/getdown-core.jar and b/j11lib/getdown-core.jar differ diff --git a/j8lib/getdown-core.jar b/j8lib/getdown-core.jar index 191df35..5ed4dc9 100644 Binary files a/j8lib/getdown-core.jar and b/j8lib/getdown-core.jar differ diff --git a/src/jalview/bin/Console.java b/src/jalview/bin/Console.java index 1bb8162..e3da4a5 100644 --- a/src/jalview/bin/Console.java +++ b/src/jalview/bin/Console.java @@ -20,20 +20,88 @@ */ package jalview.bin; +import java.io.BufferedOutputStream; +import java.io.File; +import java.io.FileNotFoundException; +import java.io.FileOutputStream; import java.io.PrintStream; +import java.util.Locale; import jalview.log.JLogger; import jalview.log.JLoggerI.LogLevel; import jalview.log.JLoggerLog4j; import jalview.util.ChannelProperties; -import jalview.util.Log4j; -import jalview.util.Platform; +import jalview.util.LaunchUtils; public class Console { public static JLoggerLog4j log; + private static PrintStream out = System.out; + + private static PrintStream err = System.err; + + private static File logfile = null; + + public static PrintStream getOut() + { + return out; + } + + public static PrintStream getErr() + { + return err; + } + + public static void setOut(PrintStream p) + { + out = p; + } + + public static void setErr(PrintStream p) + { + err = p; + } + + public static boolean setLogFile(String filename, boolean append) + { + boolean usingLogfile = false; + if (filename != null) + { + if (filename.startsWith("~/")) + { + filename = System.getProperty("user.home") + File.separator + + filename.substring(2); + } + logfile = new File(filename); + + try + { + PrintStream logFilePrintStream = new PrintStream( + new BufferedOutputStream( + new FileOutputStream(logfile, append)), + true); + + Console.setOut(logFilePrintStream); + Console.setErr(logFilePrintStream); + + Console.info(LaunchUtils.LOGFILE_HANDOVER); + + Console.info(ChannelProperties.getProperty("app_name") + .toUpperCase(Locale.ROOT) + " start of logging"); + Console.debug(ChannelProperties.getProperty("app_name") + + " logging to " + filename); + + usingLogfile = true; + } catch (FileNotFoundException e) + { + Console.errPrintln("Error opening logfile: " + e.getMessage()); + } + } + return usingLogfile; + } + public static void debug(String message, Throwable t) { if (Console.initLogger()) @@ -45,7 +113,6 @@ public class Console outPrintln(message); Console.printStackTrace(t); } - } public static void info(String message) @@ -248,15 +315,8 @@ public class Console logLevel = getCachedLogLevel(); } - if (!Platform.isJS()) - { - if (!Jalview.quiet()) - { - jalview.bin.Console.errPrintln( - "Setting initial log level to " + logLevel.name()); - } - Log4j.init(logLevel); - } + JLoggerLog4j.setLogfile(logfile); + // log output // is laxis used? Does getLogger do anything without a Logger object? // Logger laxis = Log4j.getLogger("org.apache.axis", myLevel); @@ -299,13 +359,14 @@ public class Console Console.debug("Invalid log level '" + logLevelString + "'"); return; } + setLogLevel(l); + } + + public static void setLogLevel(LogLevel l) + { if (l != null) { log.setLevel(l); - if (!Platform.isJS()) - { - Log4j.init(l); - } JLoggerLog4j.getLogger("org.apache.axis", l); } } @@ -342,11 +403,11 @@ public class Console && Jalview.getInstance().getBootstrapArgs() != null && Jalview.getInstance().getBootstrapArgs().outputToStdout()) { - return System.err; + return err; } else { - return System.out; + return out; } } @@ -376,12 +437,12 @@ public class Console public static void errPrint(Object message) { - System.err.print(message); + err.print(message); } public static void errPrintln(Object message) { - System.err.println(message); + err.println(message); } public static void debugPrintStackTrace(Throwable t) @@ -397,7 +458,7 @@ public class Console public static void printStackTrace(Throwable t) { // send message to stderr if output to stdout is expected - t.printStackTrace(System.err); + t.printStackTrace(err); } public final static String LOGGING_TEST_MESSAGE = "Logging to STDERR"; diff --git a/src/jalview/bin/Jalview.java b/src/jalview/bin/Jalview.java index f8d5c66..6b88cfa 100755 --- a/src/jalview/bin/Jalview.java +++ b/src/jalview/bin/Jalview.java @@ -21,7 +21,6 @@ package jalview.bin; import java.awt.Color; -import java.io.BufferedOutputStream; import java.io.BufferedReader; import java.io.File; import java.io.FileNotFoundException; @@ -320,42 +319,16 @@ public class Jalview implements JalviewObjectI // get args needed before proper ArgParser bootstrapArgs = BootstrapArgs.getBootstrapArgs(args); + boolean usingLogfile = false; if (!Platform.isJS()) { - boolean usingLogfile = false; // are we using a logfile? - String logFileName = System.getProperty("installer.logfile"); - if (logFileName != null) - { - try - { - if (logFileName.startsWith("~/")) - { - logFileName = System.getProperty("user.home") + File.separator - + logFileName.substring(2); - } - File logFile = new File(logFileName); - - PrintStream logFilePrintStream = new PrintStream( - new BufferedOutputStream( - new FileOutputStream(logFile, true)), - true); - - Console.info(LaunchUtils.LOGFILE_HANDOVER); - System.setOut(logFilePrintStream); - System.setErr(logFilePrintStream); - Console.info(ChannelProperties.getProperty("app_name") - .toUpperCase(Locale.ROOT) + " starting to log"); - Console.info(ChannelProperties.getProperty("app_name") - + " logging to " + logFileName); - - usingLogfile = true; - } catch (FileNotFoundException e) - { - Console.errPrintln("Error opening logfile: " + e.getMessage()); - } - } + String logfilename = System.getProperty("installer.logfile"); + boolean append = Boolean + .parseBoolean(System.getProperty("installer.logfile_append")); + + usingLogfile = Console.setLogFile(logfilename, append); // are we being --quiet ? (doesn't matter if using a logfile) if (!usingLogfile && bootstrapArgs.contains(Arg.QUIET)) @@ -363,7 +336,6 @@ public class Jalview implements JalviewObjectI QUIET = true; OutputStream devNull = new OutputStream() { - @Override public void write(int b) { @@ -424,50 +396,17 @@ public class Jalview implements JalviewObjectI }.start(); } - if (!quiet() || !bootstrapArgs.outputToStdout() + if ((usingLogfile || !quiet()) || !bootstrapArgs.outputToStdout() || bootstrapArgs.contains(Arg.VERSION)) { - Console.outPrintln( - "Java version: " + System.getProperty("java.version")); - Console.outPrintln("Java home: " + System.getProperty("java.home")); - Console.outPrintln("Java arch: " + System.getProperty("os.arch") + " " - + System.getProperty("os.name") + " " - + System.getProperty("os.version")); - - String val = System.getProperty("sys.install4jVersion"); - if (val != null) - { - Console.outPrintln("Installer version: " + val); - } - val = System.getProperty("installer.template_version"); - if (val != null) - { - Console.outPrintln("Installer template version: " + val); - } - val = System.getProperty("installer.appdir"); - if (val != null) - { - Console.outPrintln("Installer appdir: " + val); - } - val = System.getProperty("installer.extrainfo"); - if (val != null) - { - Console.outPrintln("Installer extrainfo: " + val); - } - val = System.getProperty("launcher.version"); - if (val != null) - { - Console.outPrintln("Launcher version: " + val); - } - val = appdirString; - if (val != null) + if (usingLogfile) { - Console.outPrintln("Launcher appdir: " + val); + Console.outPrintln("-------"); } - val = System.getProperty("launcher.appbase"); - if (val != null) + Console.outPrint(Cache.getVersionDetailsForConsole()); + if (usingLogfile) { - Console.outPrintln("Launcher appbase: " + val); + Console.outPrintln("-------"); } } @@ -699,6 +638,7 @@ public class Jalview implements JalviewObjectI } System.setProperty("http.agent", UserAgent.getUserAgent()); + // Initialise the logger try { Console.initLogger(); diff --git a/src/jalview/log/JLogger.java b/src/jalview/log/JLogger.java index 554b997..6d1cf06 100644 --- a/src/jalview/log/JLogger.java +++ b/src/jalview/log/JLogger.java @@ -116,11 +116,13 @@ public abstract class JLogger implements JLoggerI return registry.get(name); } + @Override public LogLevel getLevel() { return this.level; } + @Override public void setLevel(LogLevel level) { this.level = level; @@ -155,71 +157,85 @@ public abstract class JLogger implements JLoggerI } } + @Override public void trace(String message) { trace(message, null); } + @Override public void trace(String message, Throwable t) { println(LogLevel.TRACE, message, t); } + @Override public void debug(String message) { debug(message, null); } + @Override public void debug(String message, Throwable t) { println(LogLevel.DEBUG, message, t); } + @Override public void info(String message) { info(message, null); } + @Override public void info(String message, Throwable t) { println(LogLevel.INFO, message, t); } + @Override public void warn(String message) { warn(message, null); } + @Override public void warn(String message, Throwable t) { println(LogLevel.WARN, message, t); } + @Override public void error(String message) { error(message, null); } + @Override public void error(String message, Throwable t) { println(LogLevel.ERROR, message, t); } + @Override public void fatal(String message) { fatal(message, null); } + @Override public void fatal(String message, Throwable t) { println(LogLevel.FATAL, message, t); } + @Override public boolean isDebugEnabled() { return level.compareTo(LogLevel.DEBUG) <= 0; } + @Override public boolean isTraceEnabled() { return level.compareTo(LogLevel.TRACE) <= 0; diff --git a/src/jalview/log/JLoggerLog4j.java b/src/jalview/log/JLoggerLog4j.java index 22f3a55..99ed507 100644 --- a/src/jalview/log/JLoggerLog4j.java +++ b/src/jalview/log/JLoggerLog4j.java @@ -20,9 +20,12 @@ */ package jalview.log; +import java.io.File; + import org.apache.logging.log4j.Logger; import org.apache.logging.log4j.core.Appender; +import jalview.bin.Jalview; import jalview.util.Log4j; import jalview.util.Platform; @@ -30,9 +33,11 @@ public class JLoggerLog4j extends JLogger implements JLoggerI { private Logger logger = null; + private static File logfile = null; + public static JLoggerLog4j getLogger(Class c) { - return getLogger(c); + return getLogger(c.getCanonicalName()); } public static JLoggerLog4j getLogger(Class c, LogLevel loglevel) @@ -45,8 +50,24 @@ public class JLoggerLog4j extends JLogger implements JLoggerI return getLogger(name, LogLevel.INFO); } + // This must be called before Log4j.init(), so before JLoggerLog4j.getLogger() + public static void setLogfile(File f) + { + logfile = f; + } + public static JLoggerLog4j getLogger(String name, LogLevel loglevel) { + if (!Platform.isJS()) + { + if (!Jalview.quiet()) + { + jalview.bin.Console + .errPrintln("Setting log level to " + loglevel.name()); + } + Log4j.init(loglevel, logfile); + } + return registryContainsKey(name) ? (JLoggerLog4j) registryGet(name) : new JLoggerLog4j(name, loglevel); } diff --git a/src/jalview/util/Log4j.java b/src/jalview/util/Log4j.java index 6517703..67c2770 100644 --- a/src/jalview/util/Log4j.java +++ b/src/jalview/util/Log4j.java @@ -20,6 +20,7 @@ */ package jalview.util; +import java.io.File; import java.util.Map; import org.apache.logging.log4j.Level; @@ -38,6 +39,7 @@ import org.apache.logging.log4j.core.config.builder.api.AppenderComponentBuilder import org.apache.logging.log4j.core.config.builder.api.ConfigurationBuilder; import org.apache.logging.log4j.core.config.builder.api.FilterComponentBuilder; import org.apache.logging.log4j.core.config.builder.api.LayoutComponentBuilder; +import org.apache.logging.log4j.core.config.builder.api.RootLoggerComponentBuilder; import org.apache.logging.log4j.core.config.builder.impl.BuiltConfiguration; import org.apache.logging.log4j.core.filter.ThresholdFilter; import org.apache.logging.log4j.core.layout.PatternLayout; @@ -50,6 +52,8 @@ public class Log4j public final static String SIMPLE_PATTERN = "%level - %m%n"; + public final static String TIME_PATTERN = "%d{yyyy-MM-dd HH:mm:ss} %level - %m%n"; + private static boolean init = false; public static boolean isInit() @@ -67,18 +71,30 @@ public class Log4j init(log4jLevel(myLevel)); } + public static void init(JLogger.LogLevel myLevel, File logfile) + { + init(log4jLevel(myLevel), logfile); + } + public static void init(Level myLevel) { + init(myLevel, null); + } + + public static void init(Level myLevel, File logfile) + { if (init) + { return; + } try { // configure the root logger to stderr ConfigurationBuilder configBuilder = Log4j .getConfigurationBuilder(); + configBuilder.setStatusLevel(Level.INFO); - configBuilder.setStatusLevel(Level.WARN); - + // Console String consoleLoggerName = "STDERR"; AppenderComponentBuilder appenderBuilder = configBuilder .newAppender(consoleLoggerName, "Console"); @@ -88,8 +104,23 @@ public class Log4j appenderBuilder.add(Log4j.getThresholdFilterBuilder()); configBuilder.add(appenderBuilder); - configBuilder.add(configBuilder.newRootLogger(myLevel) - .add(configBuilder.newAppenderRef(consoleLoggerName))); + RootLoggerComponentBuilder root = configBuilder + .newRootLogger(myLevel); + root.add(configBuilder.newAppenderRef(consoleLoggerName)); + + if (logfile != null) + { + String fileLoggerName = "LOGFILE"; + appenderBuilder = configBuilder.newAppender(fileLoggerName, "File") + .addAttribute("fileName", logfile.getAbsolutePath()); + appenderBuilder.add(Log4j.getTimeLayoutBuilder()); + appenderBuilder.add(Log4j.getThresholdFilterBuilder()); + + configBuilder.add(appenderBuilder); + + root.add(configBuilder.newAppenderRef(fileLoggerName)); + } + configBuilder.add(root); Configurator.initialize(configBuilder.build()); @@ -124,11 +155,22 @@ public class Log4j return ConfigurationFactory.newConfigurationBuilder(); } + public static Layout getTimeLayout() + { + return PatternLayout.newBuilder().withPattern(TIME_PATTERN).build(); + } + public static Layout getSimpleLayout() { return PatternLayout.newBuilder().withPattern(SIMPLE_PATTERN).build(); } + public static LayoutComponentBuilder getTimeLayoutBuilder() + { + return getConfigurationBuilder().newLayout("PatternLayout") + .addAttribute("pattern", Log4j.TIME_PATTERN); + } + public static LayoutComponentBuilder getSimpleLayoutBuilder() { return getConfigurationBuilder().newLayout("PatternLayout") diff --git a/src/jalview/ws/jws2/Jws2Discoverer.java b/src/jalview/ws/jws2/Jws2Discoverer.java index 2e4631f..ed40b84 100644 --- a/src/jalview/ws/jws2/Jws2Discoverer.java +++ b/src/jalview/ws/jws2/Jws2Discoverer.java @@ -20,16 +20,6 @@ */ package jalview.ws.jws2; -import jalview.bin.Cache; -import jalview.bin.Console; -import jalview.gui.AlignFrame; -import jalview.gui.Desktop; -import jalview.gui.JvSwingUtils; -import jalview.util.MessageManager; -import jalview.ws.WSMenuEntryProviderI; -import jalview.ws.jws2.jabaws2.Jws2Instance; -import jalview.ws.params.ParamDatastoreI; - import java.awt.Color; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; @@ -53,6 +43,15 @@ import javax.swing.JMenu; import javax.swing.JMenuItem; import compbio.ws.client.Services; +import jalview.bin.Cache; +import jalview.bin.Console; +import jalview.gui.AlignFrame; +import jalview.gui.Desktop; +import jalview.gui.JvSwingUtils; +import jalview.util.MessageManager; +import jalview.ws.WSMenuEntryProviderI; +import jalview.ws.jws2.jabaws2.Jws2Instance; +import jalview.ws.params.ParamDatastoreI; /** * discoverer for jws2 services. Follows the lightweight service discoverer @@ -314,7 +313,7 @@ public class Jws2Discoverer implements Runnable, WSMenuEntryProviderI { services = new Vector<>(); } - jalview.bin.Console.outPrintln( + jalview.bin.Console.info( "Discovered service: " + jwsservers + " " + service.toString()); // Jws2Instance service = new Jws2Instance(jwsservers, srv.toString(), // service2); diff --git a/utils/dev_install.sh b/utils/dev_install.sh index 5648bf5..5b70b50 100755 --- a/utils/dev_install.sh +++ b/utils/dev_install.sh @@ -180,7 +180,7 @@ case $OS in echo "Removing '$APPLICATIONS/$APP.app'" /bin/rm -r "$APPLICATIONS/$APP.app" echo "Syncing '$MOUNTEDAPP' to '$APPLICATIONS/'" - rsync -avh "$MOUNTEDAPP" "$APPLICATIONS/" + rsync --delete -avh "$MOUNTEDAPP" "$APPLICATIONS/" echo "Unmounting '/Volumes/$INSTALLERVOL'" hdiutil detach "/Volumes/$INSTALLERVOL" else diff --git a/utils/install4j/install4j10_template.install4j b/utils/install4j/install4j10_template.install4j index ed4ef85..59d5079 100644 --- a/utils/install4j/install4j10_template.install4j +++ b/utils/install4j/install4j10_template.install4j @@ -149,7 +149,7 @@ - +