Wildcards & Operators
Wild Card
Description
Example
Description
*
Any character
*.txt
Anything that ends with .txt
?
Single character
Passw?rd
Anything that starts with Passw ends with rd and has 1 more letter inbetween that can be anything.
[]
Set of characters (Can also specify a range)
[abc]*
Anything that starts with a, b, or c.
{}
Set of sets
{\*.doc,\*.pdf}
Anything that ends with .doc or .pdf
[!]
Not set of characters
file[!9].pdf
Any file that ends with .pdf execulding file9.pdf.
\
Escape Character
"\*"
Search for *, regardless of its functionality as a wildcard.
Operator
Description
&
Runs commands in the background.
&&
Combine multiple commands (Runs next command if the previous command was sucessful)
>
Redirects output (Overwrite)
>>
Redirects output (Without Overwriting)
Last updated