parse .gitignore file
Project description
pyignore
==========================
Parse file like `.gitignore`.
I write this because, there are no good ignore parsers lib for python.
## Usage
ign = Ignore(['foo/', '/*/*.pyc', '*.txt'])
print ign
names = ['/log/foo/', '/foo', '/bar/', '/x.pyc', '/foo/a.pyc', '/foo/a.py', '/foo/a.txt']
print 'names', names
print ign.exclude(names)
print ign.filter(names)
Licence under [MIT](LICENSE)
==========================
Parse file like `.gitignore`.
I write this because, there are no good ignore parsers lib for python.
## Usage
ign = Ignore(['foo/', '/*/*.pyc', '*.txt'])
print ign
names = ['/log/foo/', '/foo', '/bar/', '/x.pyc', '/foo/a.pyc', '/foo/a.py', '/foo/a.txt']
print 'names', names
print ign.exclude(names)
print ign.filter(names)
Licence under [MIT](LICENSE)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pyignore-0.1.tar.gz
(2.0 kB
view hashes)