. | Match any single character except newline. |
* | Match any number (or none) of the single character that immediately precedes it. The preceding character can also be a regular expression. E.g., since . (dot) means any character, .* means "match any number of any character." |
^ | Match the following regular expression at the beginning of the line. |
$ | Match the preceding regular expression at the end of the line. |
[ ] | Match any one of the enclosed characters. |
| A hyphen (- ) indicates a range of consecutive characters. A circumflex (^ ) as the first character in the brackets reverses the sense: it matches any one character not in the list. A hyphen or close bracket (] ) as the first character is treated as a member of the list. All other metacharacters are treated as members of the list. |
\{ n ,m \} | Match a range of occurrences of the single character that immediately precedes it. The preceding character can also be a regular expression. \{n\} matches exactly n occurrences, \{n \} matches at least n occurrences, and \{n,m\} matches any number of occurrences between n and m. n and m must be between 0 and 256, inclusive. |
\ | Turn off the special meaning of the character that follows. |
\( \) | Save the pattern enclosed between \( and \) into a special holding space. Up to nine patterns can be saved on a single line. They can be "replayed" in substitutions by the escape sequences \1 to \9. |
\< \> | Match characters at beginning (\<) or end (\>) of a word. |
+ | Match one or more instances of preceding regular expression. |
? | Match zero or one instances of preceding regular expression. |
| | Match the regular expression specified before or after. |
( ) | Apply a match to the enclosed group of regular expressions. |