Tea is a standard Unix command. Its name derives from the tee, install a junction with the plumber in a line.
The command reads data from stdin and outputs to stdout and to a ( newly created or existing ) file. It is used to obtain intermediate results within a pipe. They may be used for failure analysis, or further processed in other pipes.
Existence and scope of functions and behavior of this command is supported both by the Single Unix Specification (SUS ) and the POSIX standard (or, tantamount, the IEEE Standard 1003.1 ) for standard Unixes standardized.
The standard according understands tee two options: with -a is appended to the specified file ( instead of opening a new blank file) and with -i, the signal SIGINT is ignored.
The command is also contained in the GNU core utilities.
This example filters the files and directories in the root directory for all, containing a 'b'. At the same time a file ' out.file ' is created with all the files and directories in the root directory.
Ls -l / | tee out.file | grep b Web Links
- Tee (1) - Debian GNU / Linux Executable programs or shell commands manual page
- Tee in SUS V2