Eric Blake wrote: > According to Stephane Chazelas on 10/29/2008 3:32 AM:
>>>> : > stdout > stderr >>> >>> For shell portability, I'll write the first line as >>> : > stdout >>> : > stderr >>> though. >> >> Why? > > It fails on old Ultrix sh, which can't redirect the same fd more than once > in a single statement. But that platform is relatively dead these days. More detailed: - It actually works (also on Ultrix) but it is not robust in any traditional Bourne shell (except where fixed by the vendor): $ echo x y > file1 > file2 # ok, all output in file2 $ echo x > file1 y > file2 # not ok, all output in file1 instead of file2 - the abovementioned repeated redirecting fails in other constructs: $ eval 'echo x > file1' > file2 illegal io This was fixed with SVR2 (thus on Ultrix with sh5). [OT on bug-bash but I'll keep the cc]