] [ string1 [ string2 ] ]
copies the standard input to the standard output with
substitution or deletion of selected characters.
Input characters found in
are mapped into the corresponding characters of
is short, it is padded with corresponding characters from
Any combination of the options
complements the set of characters in
with respect to the universe of characters
whose ascii codes are 001 through 377 octal.
deletes all input characters not in
squeezes all strings of repeated output characters that are
The following abbreviation conventions may be used
to introduce ranges of characters or repeated characters into
\fB[\fIa\*|\fB\*-\fIb\fB\*|]\fR
stands for the string of characters whose ascii codes run
\fB[\fIa\fB\*|*\fIn\fB\*|]\fR,
is an integer or empty, stands for \fIn\fR-fold
is taken to be octal or decimal according as its
first digit is or is not zero.
this facility is useful for padding
The escape character `\\' may be used as in
to remove special meaning from any character in a string.
`\\' followed by 1, 2 or 3 octal digits stands for the
character whose ascii code is given by those digits.
The following example creates a list of all
the words in `file1' one per line in `file2',
where a word is taken to be a maximal string of alphabetics.
to protect the special characters from interpretation by the Shell;
012 is the ascii code for newline.
tr \*-cs "[A\*-Z][a\*-z]" "[\\012*]" <file1 >file2
Also, Kernighan's Lemma can really bite you;
try looking for strings which have \\ and * in them.