Regex Mastery

Regex Mastery

Attribute Value

Goal

Fluent regex across all contexts

Interest Link

Systems Tools > Text Processing

Status

In Progress

Contexts

grep/ripgrep, sed, awk, vim, Python

Documentation

Principia/02_Assets/LRN-REGEX-MASTERY/

Regex Flavors

Flavor Context Status

BRE

grep, sed (default)

[x] Proficient

ERE

grep -E, awk

[x] Proficient

PCRE

grep -P, Python, ripgrep

[ ] In Progress

Vim regex

:s/, search, :g

[ ] In Progress

Python re

re module, named groups

[ ] In Progress

Pattern Categories

Category Examples Status

Character classes

[a-z], \d, \w, \s

[x] Done

Anchors

^, $, \b, \<, \>

[x] Done

Quantifiers

*, +, ?, \{n,m}, lazy vs greedy

[x] Done

Groups

(pattern), (?:pattern), back-references

[ ] In Progress

Lookahead/behind

(?=), (?!), (?⇐), (?<!)

[ ] Learning

Named groups

(?P<name>pattern)

[ ] Learning

Unicode

\\p{L}, \\p{N}, Unicode categories

[ ] Not Started