have direfenre between >&, &>, 2>&1 and 1>&2 ?
have direfenre between >&, &>, 2>&1 and 1>&2 ?
explation please. thanks in advance! |
This is all in the man page for your shell. If you're using bash for your shell, type man bash and search for redirection. Briefly though, if you are using bash...
&>word and >&word are functionally the same, they both redirect the standard output and standard error to word. In bash, the first form is preferred. 2>&1 redirects standard error to the standard output and 1>&2 redirects standard output to the standard error. |
All times are GMT -5. The time now is 06:52 AM. |