Skip to content

Instantly share code, notes, and snippets.

@LarryWeiss
Created August 27, 2016 16:18
Show Gist options
  • Save LarryWeiss/0e19b8365acf02a01910be4f037e5888 to your computer and use it in GitHub Desktop.
Save LarryWeiss/0e19b8365acf02a01910be4f037e5888 to your computer and use it in GitHub Desktop.
output redirection operators
output redirection where α is a command and ß and γ are filenames
------------------------------------------------------------------
α > ß only regular output - override
α >> ß only regular output - append
α 2> ß only error output - override
α 2>> ß only error output - append
α 2>&1> ß both regular output and error output, merged - overide
α 2>&1>> ß both regular output and error output, merged - append
α >ß 2>γ both regular output and error output, separately - both override
α >>ß 2>>γ both regular output and error output, separately - both append
α >ß 2>>γ both regular output and error output, separately - regular override, error append
α >>ß 2>γ both regular output and error output, separately - regular append, error override
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment