tr <string1> [string2]
Translate characters
Arguments
Name | Description |
---|---|
string1 | Candidate string |
string2 | Replacment string |
Options
Name | Description |
---|---|
-C | Complement the set of characters in string1, that is '-C ab' includes every character except for 'a' and 'b' |
-c | Same as '-C' but complement the set of values in string1 |
-d | Delete characters in string1 from the input |
-s | Squeeze multiple occurrences of the characters listed in the last operand (either string1 or string2) in the input into a single instance of the character. This occurs after all deletion and translation is completed |
-u | Guarantee that any output is unbuffered |