I’ve been having some troubles redirecting a batch file to a log file as well as having it display in the command console.
Is this even possible with windows batch, or do I have to resort to a simple program which intercepts stdout and writes the stream to a file and to stdout?
I don’t think you can do this (properly) with just the built-in tools, you probably need to use a tee utility like the Win32 GNU ports (this or this) or mtee
Edit:
You can of course use the FOR batch command, but the output is not live, you have to wait for the command to finish: