user28356: I can get this to work in a Windows Command Prompt window as follows:
stockfish_14_x64_modern.exe 
uci 
ucinewgame 
position fen rnb1kbnr/ppp1pppp/8/3q4/8/8/PPPP1PPP/RNBQKBNR w KQkq - 0 1 
go depth 17 
quit 
If I put this into batch file and pipe the output to a log file, the log file contains output up to and including the uciok line. Note that the batch file is a single, long line. The parameters are not one-per-line.


user19332: Assuming the question is about fixing the width formatting of the windows command window when copying text directly from that:
Have you tried :
uci
....
then when ready.
setoption name Debug Log File type string default
All subsequent commands should be executed, echoed in command window and the output file, as well as all output from SF.
It actually works, and I verified that the CRLF correspond to each SF output lines, not those of the DOS window maximal width.
"type string default"?
need to carefully read the UCI protocol, excerpted here:

setoption name  [value ]
this is sent to the engine when the user wants to change the internal parameters    of the engine. For the "button" type no value is needed.    One string will be sent for each parameter and this will only be sent when the engine is waiting.   The name of the option in  should not be case sensitive and can include spaces like also the value. The substring "value" and "name" should be avoided in  and  to allow unambiguous parsing,
for example do not use  = "draw value".

In other words, after deduction and testing, write without the quotes (there to emphasize what is required in using the uci definition above)
"Setoption name Debug Log File" "value" YouroutputFilepath
YouroutputFilepath = typical windows path including filename.
or just a file name for a file in your Stockfish executable folder.

28356: <p>I can get this to work in a Windows Command Prompt window as follows:</p>
<p><em><strong>stockfish_14_x64_modern.exe <br/>
uci <br/>
ucinewgame <br/>
position fen rnb1kbnr/ppp1pppp/8/3q4/8/8/PPPP1PPP/RNBQKBNR w KQkq - 0 1 <br/>
go depth 17 <br/>
quit <br/></strong></em></p>
<p>If I put this into batch file and pipe the output to a log file, the log file contains output up to and including the <em><strong>uciok</strong></em> line. Note that the batch file is a single, long line. The parameters are not one-per-line.</p>
<p><a href="https://i.stack.imgur.com/S6BTa.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/S6BTa.png" alt="Screen Shot" /></a></p>
 19332: <p>Assuming the question is about fixing the width formatting of the windows command window when copying text directly from that:</p>
<p>Have you tried :
uci
....
then when ready.</p>
<p><strong>setoption name Debug Log File type string default</strong></p>
<p>All subsequent commands should be executed, echoed in command window and the output file, as well as all output from SF.</p>
<p>It actually works, and I verified that the CRLF correspond to each SF output lines, not those of the DOS window maximal width.</p>
<p>&quot;type string default&quot;?
need to carefully read the UCI protocol, excerpted here:</p>
<ul>
<li>setoption name  [value ]
this is sent to the engine when the user wants to change the internal parameters    of the engine. <strong>For the &quot;button&quot; type no value is needed</strong>.    One string will be sent for each parameter and this will only be sent when the engine is waiting.   The name of the option in  should not be case sensitive and can include spaces like also the value. The substring &quot;<strong>value</strong>&quot; and &quot;<strong>name</strong>&quot; should be avoided in  and  to allow unambiguous parsing,
for example do not use  = &quot;draw value&quot;.</li>
</ul>
<p>In other words, after deduction and testing, write without the quotes (there to emphasize what is required in using the uci definition above)</p>
<p><strong>&quot;Setoption name Debug Log File&quot; &quot;value&quot; YouroutputFilepath</strong></p>
<p>YouroutputFilepath = typical windows path including filename.
or just a file name for a file in your Stockfish executable folder.</p>
