Skip to content

Glossary: Command Line for IT: Bash and PowerShell

-match

Also written: -cmatch

A PowerShell operator that tests a string against a regular expression and answers True or False. When it matches, it puts the groups in $Matches; it ignores case, while -cmatch pays attention to case.

Where the book teaches it

Related terms

$Matchesregular expression (regex)-replace