Title: Introduction to Regular Expressions
Course: CIS 121: Linux/UNIX I: Fundamentals ~ For IGNITE Review > Section: Learning Modules

Regular Expressions (Reg Ex) have their origin in formal language theory.  They were developed by Stephen Kleene in the 1950s and became widely used in the UNIX environment. They are not just a “UNIX thing”, but are used in other programming environments such as Perl.

We will be dealing with limited or Basic Regular Expressions (BRE). The only commands that we will study that use Reg Ex are grep and sed. It is easy to get confused between Regular Expressions ( . [] [^] ^ $ * \ ) and the bash command line wildcards (? * []).

We will learn about a subset of what Regular Expressions can do. The individual components are fairly straightforward. Things get more interesting as we combine expressions in one command.