in reply to Re: How do I get output from the perl debugger (perl -d) into a text file?
in thread How do I get output from the perl debugger (perl -d) into a text file?

Okay... tee for windows is downloadable at http://unxutils.sourceforge.net/. I'm trying it out now... and..

It doesn't quite work. tee does print out to that log file, but it only seems to be printing what normally would be coming out of stdout. Perhaps if I could trap the stderr stuff into tee I would get the debug output as well. Any ideas?

  • Comment on Re^2: How do I get output from the perl debugger (perl -d) into a text file?

Replies are listed 'Best First'.
Re^3: How do I get output from the perl debugger (perl -d) into a text file?
by jhourcle (Prior) on Aug 01, 2005 at 13:14 UTC

    I'd recommend the unix 'script' command, but be warned -- it will also save control characters, which makes for some interesting reading if you try to pop it open in your favorite text editor.

    You can clean up a script file using the unix command 'col'.

    You can also use logging in your terminal program (tf or similar, if your current terminal doesn't support that function) or use something like 'screen'.

    Update: For those who aren't aware, windows users can make use of unix commands via programs like cygwin. Another useful command.com replacement is 4DOS and its siblings.

      open DB::OUT, ">&STDOUT"

      Do that after you've started the debugger (piped through tee) but before you've done anything too insteresting.

      - tye