The vertical bar character is used to represent a pipe in commands in Linux and other Unix-like operating systems. A pipe is a form of redirection that is used to send the output of one program to another program for further processing.
Another common use for the vertical bar character in computer software, such as in regular expressions and when indicating the syntax of a command, is to indicate or, that is, to separate alterative possibilities.
A regular expression is a string (i.e., sequence of characters) that is used to describe or match some set of strings. Regular expressions are commonly used in text editors and programming languages for searching for and manipulating text. For example,
Created August 5, 2007.
Copyright © 2007 The Linux Information Project. All Rights Reserved.