Say you have a "Projects" directory and you want to back it up, but only certain files, and ignore others depending on certain conditions: >>> import pathspec >>> # The gitignore-style patterns for ...