Re: [Mingw-users] messages
- Date: Sat, 29 Dec 2007 22:53:24 +0100
- From: Michael Gerdau <mgerdau@xxxxxxxxxx>
- Subject: Re: [Mingw-users] messages
> tried every combination of 1>&messages.txt 2>&1 > Ampersands always become part of the filename. I haven't followed this discussion from the start but the above line most likely does not do what you want it to. I assume what you are looking for is some like some_command >my_logile.txt 2>&1 which is a shorthand version of some_command 1>my_logile.txt 2>&1 It does redirect the stuff written to STDOUT (filehandle 1) to the file my_logfile.txt. It then does redirect STDERR (filehandle 2) to STDOUT (filehandle 1) which in turn is already redirected to my_logfile.txt. Giving "&1" instructs the shell to not write to a file named "&1" (or "1") but to the filehandle number 1 (which usually is stdout). In other words: writing "&" directly followed by a digit (or number) is a special syntax to write to filehandles. Not sure this does help you with your original problem but it definitely should redirect all msgs (both stdout and stderr) to the desired file. Best, Michael -- Michael Gerdau email: mgerdau@xxxxxxxxxx GPG-keys available on request or at public keyserver
Attachment:
signature.asc
Description: This is a digitally signed message part.
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________ MinGW-users mailing list MinGW-users@xxxxxxxxxxxxxxxxxxxxx You may change your MinGW Account Options or unsubscribe at: https://lists.sourceforge.net/lists/listinfo/mingw-users
- Follow-Ups:
- Re: [Mingw-users] messages
- From: Keith Marshall
- Re: [Mingw-users] messages
- References:
- Re: [Mingw-users] messages
- From: alpha-quadrant
- Re: [Mingw-users] messages
- Prev by Date: Re: [Mingw-users] Problem with crossed native build of gcc 4.2.2
- Next by Date: Re: [Mingw-users] Cross compiling
- Previous by thread: Re: [Mingw-users] messages
- Next by thread: Re: [Mingw-users] messages
- Index(es):