Craig
Craig

Reputation: 991

cmd.exe equivalent of /dev/stdout, to write to stdout 'as a file'

I have a batch file that calls a Windows GUI application. The GUI app writes it's output (the interesting bits anyway) to it's own GUI display rather than stdout, however I would like it displayed in the cmd window where the batch file is running.

Thankfully the app has an option to write the output to a file, so I need to redirect this to stdout. In *nix I would give /dev/stdout as the file to write to but what about in Windows/cmd?

Upvotes: 5

Views: 6046

Answers (2)

Arun
Arun

Reputation: 2533

con is the equivalent of /dev/stdout and /dev/stderr in Windows. But I am not sure how you are writing the output. It will help if you could paste the block that writes to the file.

Upvotes: 2

cedrou
cedrou

Reputation: 2790

It seems that Windows has no equivalent to unix /dev/stdout.

Take a look at this thread: https://superuser.com/questions/241272/windows-how-to-redirect-file-parameter-to-stdout-windows-equivalent-of-dev-st

Upvotes: 4

Related Questions