cp /path/src/*.{gif,jpg} /path/dest
Info about wildcards and globbing patterns.
In particular:
{ } (curly brackets)
terms are separated by commas and each term must be the name of something or a wildcard. This wildcard will copy anything that matches either wildcard(s), or exact name(s) (an “or” relationship, one or the other).
For example, this would be valid:
cp {*.doc,*.pdf} ~
This will copy anything ending with .doc or .pdf to the users home directory. Note that spaces are not allowed after the commas (or anywhere else).
jpg
matches ANDgif
matches, this is technically an OR expression, because you want to match either pattern1 OR pattern2.