cons-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Cons output on NT


From: Jeff Rosenfeld
Subject: RE: Cons output on NT
Date: Mon, 2 Oct 2000 14:37:24 -0700

The NT cmd.exe doesn't seem to like to redirect output from (or input to) a
script. To work around that problem, bat-ify cons.pl by putting the
following lines at the very top of the file and renaming it to cons.bat:

        @rem = <<'';  # '--*-Perl-*--'
        @perl %~f0 %*
        @goto :eof

        #!perl

Note that you *do* need that blank line after the goto.

        - Jeff.

P.S.: Activestate perl comes with a script to do this for you and that works
with a wider assortment of DOS/NT shells.

>>> -----Original Message-----
>>> From: Zachary Deretsky [mailto:address@hidden
>>> Sent: Monday, October 02, 2000 1:43 PM
>>> To: address@hidden
>>> Subject: Cons output on NT
>>> 
>>> 
>>> How to capture cons output into a log file on NT?
>>> 
>>> cons -- -debug
>>> is my regular run which outputs to the DOS window.
>>> 
>>> I tried
>>> 
>>> cons.pl -- -debug > cons.log
>>> cons.pl -- -debug | tee cons.log
>>> 
>>> tee here is mks tee.
>>> 
>>> Nothing works, I can only see the output in the DOS window.
>>> 
>>> It would be very useful to have an option in cons to print 
>>> into a log file,
>>> with or without STDOUT and STDERR.
>>> 
>>> Thanks, Zach.
>>> 
>>> _______________________________________________
>>> address@hidden
>>> http://mail.gnu.org/mailman/listinfo/cons-discuss
>>> Cons URL: http://www.dsmit.com/cons/
>>> 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]