A pipe is a chain of processes so that output of one process (stdout) is fed an input (stdin) to another. UNIX shell has a special syntax for creation of pipelines. The commands are written in sequence separated by |. Different filters are used for Pipes like AWK, GREP.
E.g. sort file | lpr ( sort the file and send it to printer)
Uses of Pipe
Several powerful functions can be in a single statement
Streams of processes can be redirected to user specified locations using >
E.g. sort file | lpr ( sort the file and send it to printer)
Uses of Pipe
Several powerful functions can be in a single statement
Streams of processes can be redirected to user specified locations using >
No comments:
Post a Comment