= Redirection = Redirection is the shell's mechanism for opening, closing, duplicating, and performing other manipulations on [[FileDescriptor|file descriptors]]. Redirection is either the last or second-to-last (depending on the shell and command) step of simple-command evaluation prior to running the command itself. == Links == * [[https://web.archive.org/web/20230412163832/https://wiki.bash-hackers.org/howto/redirection_tutorial|Illustrated redirection tutorial]] (recommended), [[https://web.archive.org/web/20230326220915/http://wiki.bash-hackers.org/syntax/redirection|redirection reference]], and [[https://web.archive.org/web/20230208032810/https://wiki.bash-hackers.org/scripting/copydescriptor|understanding the copy descriptor]] on the bash-hackers wiki. * The [[http://www.gnu.org/software/bash/manual/bashref.html#Redirections|Bash manual]] includes complete documentation. A quick reference is available on the [[BashSheet#Redirection|BashSheet]]. * [[BashFAQ/055|FAQ 55]] provides a basic introduction, and the [[BashGuide/InputAndOutput#Redirection|BashGuide]] has a very short non-technical introduction. * The portable types of redirects are [[http://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_07|specified by POSIX]] ---- CategoryShell