Redirect standard output and error output to one file instead of console
|Posted on: 2011-02-14 05:48:08 |
|IP: Logged |
Going to post this here because I keep forgetting..|
It is possible on linux to redirect both the standard output AND the error output and append the result to one file.
The trick here is to specify the file redirection first and then the error console redirection:
:::you@yourcomp:/tmp::: yourcommand >>outfile.txt 2>&1