perl - Redirecting the output of expect to logfile in expect -


I'm using the expectation in Perl I want to redirect all the outputs that appear in a log file on the stdout console So that I can debug it in the future. Currently I'm using $ exp-> log_stdout (0); Can I do this in the log file instead of its redirection? If so how to do it?

If you are looking at the documentation, you will see information about the log session in the file Will get

  $ object-> Log_file ("file name" | $ filehandle | | & amp; coderef | undef)  

send all letters or files received from the derivative process are written. Usually adds to the logfile, but you can pass an additional mode of "w" to filter the file on the open ():

  $ object-> Log_file ("filename", "w");  

This means use the log_file method instead of log_stdout .

Your problem will be solved


Comments

Popular posts from this blog

c# - sqlDecimal to decimal clr stored procedure Unable to cast object of type 'System.Data.SqlTypes.SqlDecimal' to type 'System.IConvertible' -

Calling GetGUIThreadInfo from Outlook VBA -

Obfuscating Python code? -