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

Re: Redirecting stdout and stderr into a file



Otto Wyss wrote:

Sorry I can't remember how I can redirect the stdout and stderr together
into a file. I can

grep > logfile
grep 2> logfile

but how can I redirect both together?
cat foo 2>&1 > logfile
or, to append to the file:
cat foo 2>&1 >> logfile

Should do it.

Regards,

Upayavira




Reply to: