redirection
Bash combined output
Bash-specific form combining stdout and stderr into a single output file, truncating if permitted.
Formal Syntax & Structure
bash syntaxbash
&>fileReturn Value
redirection effect
Bash-specific form combining stdout and stderr into a single output file, truncating if permitted.
Working Example
Example Snippetbash
report() { printf '%s\n' data; printf '%s\n' note >&2; }report &> combined.logreport &>> combined.logcat combined.log