Advertisement
Guest User

Untitled

a guest
Jun 15th, 2019
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. dir >> out 2>> error
  2.  
  3. dir >> consolidate 2>&1
  4.  
  5. (command > >(tee out.txt) 2> >(tee error.txt >&2)) &> consol.txt
  6.  
  7. $ ls
  8. f
  9.  
  10. $ ls g*
  11. ls: cannot access g*: No such file or directory
  12.  
  13. $ (ls g f > >(tee out.txt) 2> >(tee error.txt >&2)) &> consol.txt
  14.  
  15. $ cat out.txt
  16. f
  17.  
  18. $ cat error.txt
  19. ls: cannot access g: No such file or directory
  20.  
  21. $ cat consol.txt
  22. f
  23. ls: cannot access g: No such file or directory
  24.  
  25. { { dir | tee -a out; } 2>&1 >&3 | tee -a error; } >> consolidate 3>&1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement