#### 43.1.3 Monitoring system command execution

To make system commands (and Windows system responses) visible in a command-prompt window while a conversion is running:

    [Automation]
    ; SystemCommandWindow =
    ;  Hide (default, no display),
    ;  Show (show during execution only),
    ;  Keep (show until user dismisses)
    SystemCommandWindow = Show

When you specify Show or Keep for SystemCommandWindow, the system-command.bat file starts with the following lines:

    REM For: path\to\sourcefilename
    @ECHO Running batfilename
    @ECHO ON

The @ECHO ON command causes the rest of the commands in the .bat file to be visible as they are executed; however, the display might be very brief unless you have a huge project. If there is an error, the error message displays even before the Running batfilename line, an unavoidable Windows feature (because stderr cannot be redirected to stdout).

The next line in the .bat file after your system command is:

    @ECHO Finished batfilename

If SystemCommandWindow=Keep, the .bat file ends with:

    @PAUSE

so that you can see what happened.

Note: Do not specify SystemCommandWindow=Keep for unattended use, because the .bat file would wait forever for you to press a key.

The .bat file remains in the project directory, so you can see what it contains. The next time you run the same kind of command, DITA2Go recycles the .bat file.

Previous Topic: 43.1.2 Including macros and variables in system commands

Next Topic: 43.1.4 Supplying system commands in a .bat file

Parent Topic: 43.1 Executing operating-system commands

Sibling Topics:

43.1.1 Specifying system commands

43.1.2 Including macros and variables in system commands

43.1.4 Supplying system commands in a .bat file

43.1.5 Supplying system commands in a macro