Minimize the batch execution

This is not perfect, but the batch script should run twice, and the
second time it will be minimized.