summaryrefslogtreecommitdiff
blob: 9ae1e0667b9e8dc9353685f7325b54792840dcef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#!/usr/bin/env python

"""find empty dirs"""

import os
from os.path import join, getsize
for root, dirs, files in os.walk('.'):
    for ignoredir in ('CVS','.svn','xfce-base','xfce-extra','eclass'):
        if ignoredir in dirs:
            dirs.remove(ignoredir)
    if len(dirs)+len(files) == 0:
        print root, "seems to be empty"