python copytree with negated ignore pattern
- by Chris H
I'm trying to use python to copy a tree of files/directories.
is it possible to use copytree to copy everything that ends in foo?
There is an ignore_patterns patterns function, can I give it a negated regular expression? Are they supported in python?
eg.
copytree(src, dest, False, ignore_pattern('!*.foo'))
Where ! means NOT anything that ends in foo.
thanks.