protected static String usage(String executableBaseName) { boolean isWindows = (WildFlySecurityManager.getPropertyPrivileged("os.name", null)).toLowerCase(Locale.ENGLISH).contains("windows"); String executableName = isWindows ? executableBaseName : executableBaseName + ".sh"; if (USAGE == null) { final StringBuilder sb = new StringBuilder(); sb.append(NEW_LINE).append(ProcessLogger.ROOT_LOGGER.argUsage(executableName)).append(NEW_LINE); for (int i = 0; i < arguments.size(); i++) { sb.append(getCommand(i)).append(NEW_LINE); } USAGE = sb.toString(); } return USAGE; }
protected static String usage(String executableBaseName) { boolean isWindows = (SecurityActions.getSystemProperty("os.name")).toLowerCase(Locale.ENGLISH).contains("windows"); String executableName = isWindows ? executableBaseName : executableBaseName + ".sh"; if (USAGE == null) { final StringBuilder sb = new StringBuilder(); sb.append(NEW_LINE).append(MESSAGES.argUsage(executableName)).append(NEW_LINE); for (int i = 0; i < arguments.size(); i++) { sb.append(getCommand(i)).append(NEW_LINE); } USAGE = sb.toString(); } return USAGE; }
protected static String usage(String executableBaseName) { boolean isWindows = (WildFlySecurityManager.getPropertyPrivileged("os.name", null)).toLowerCase(Locale.ENGLISH).contains("windows"); String executableName = isWindows ? executableBaseName : executableBaseName + ".sh"; if (USAGE == null) { final StringBuilder sb = new StringBuilder(); sb.append(NEW_LINE).append(ProcessLogger.ROOT_LOGGER.argUsage(executableName)).append(NEW_LINE); for (int i = 0; i < arguments.size(); i++) { sb.append(getCommand(i)).append(NEW_LINE); } USAGE = sb.toString(); } return USAGE; }