View Full Version : cli logging
juGGaKNot
17th May 2009, 20:32
Hi.
I'm going out of my mind, i can't get logging to work
I want everything i see in the cmd to be logged to a .txt file at the end.
i tried > .txt but it does not work, how can i log stderr, stdin and stdout ?
So what can i use and where should i put it in the bat ?
Dark Shikari
17th May 2009, 20:45
2> logs stderr.
juGGaKNot
17th May 2009, 21:09
2> logs stderr.
'stderr.' is not recognized as an internal or external command,
operable program or batch file.
windows xp and vista is the target.
Dark Shikari
17th May 2009, 21:13
'stderr.' is not recognized as an internal or external command,
operable program or batch file.
windows xp and vista is the target.Do I have to make it clearer?
"2>" logs stderr. That's what it does. It logs stderr.
juGGaKNot
17th May 2009, 21:18
Do I have to make it clearer?
"2>" logs stderr. That's what it does. It logs stderr.
It does not work ( i do not know how to use it )
Any examples ?
Dark Shikari
17th May 2009, 21:19
It does not work ( i do not know how to use it )
Any examples ?command blah blah blah 2> file.txt
juGGaKNot
17th May 2009, 21:22
command blah blah blah 2> file.txt
yes i tried that, stderr is not bla bla bla
+ i want only what i see on the screen with 2> i get it all, frame by frame ( for faac and mp4box ) and for x264 i do not get anything.
ah and 2> i do not see it on the screen, just in the log.
maybe some external app ? mtee (http://commandline.co.uk/mtee/index.html) ?
Dark Shikari
17th May 2009, 21:23
yes i tried that, stderr is not bla bla bla
+ i want only what i see on the screen with 2> i get it all, frame by frame ( for faac and mp4box ) and for x264 i do not get anything.Yes, because those programs output to stdout, not stderr.
ah and 2> i do not see it on the screen, just in the log.Yes, because you're redirecting the output to a file.
Learn how to use "tee" if you want it in both places.
juGGaKNot
17th May 2009, 21:26
Learn how to use "tee" if you want it in both places.
Ahh so mtee is the way to go
tee does not exist for windows xp from what i've read.
J_Darnley
18th May 2009, 01:08
Ahh so mtee is the way to go
tee does not exist for windows xp from what i've read.
Sure it does. Just because it doesn't come with Windows doesn't mean it doesn't exist. There are two native versions (1 (http://unxutils.sourceforge.net/) 2 (http://gnuwin32.sourceforge.net/)) and one for cygwin
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.