Improve command logging in Script class to include full command line when debugging

This commit is contained in:
chenyoulong20g@ict.ac.cn 2025-11-11 18:12:29 +08:00
parent 30fed1ae93
commit 64a6547cf3
1 changed files with 2 additions and 2 deletions

View File

@ -246,8 +246,8 @@ public class Script implements Callable<String> {
public String execute(OutputInterpreter interpreter) {
String[] command = _command.toArray(new String[_command.size()]);
String commandLine = buildCommandLine(command);
if (_logger.isDebugEnabled() && !avoidLoggingCommand) {
_logger.debug(String.format("Executing command [%s].", commandLine.split(KeyStoreUtils.KS_FILENAME)[0]));
if (_logger.isDebugEnabled() ) {
_logger.debug(String.format("Executing command [%s].", commandLine));
}
try {