summaryrefslogtreecommitdiff
path: root/morphlib/bins.py
diff options
context:
space:
mode:
authorLars Wirzenius <lars.wirzenius@codethink.co.uk>2011-11-03 17:59:45 +0000
committerLars Wirzenius <lars.wirzenius@codethink.co.uk>2011-11-03 17:59:45 +0000
commit75b4a19d8d43f634fd85a219b0b642fcd36cc505 (patch)
treeb0f8d9fff1c482f7cf870812f6a26250f3c547af /morphlib/bins.py
parentd5821c88529beacf47427f490957123480a62768 (diff)
downloadmorph-75b4a19d8d43f634fd85a219b0b642fcd36cc505.tar.gz
Output multiple chunks when requested
Diffstat (limited to 'morphlib/bins.py')
-rw-r--r--morphlib/bins.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/morphlib/bins.py b/morphlib/bins.py
index 993ae3ad..3381bc28 100644
--- a/morphlib/bins.py
+++ b/morphlib/bins.py
@@ -79,7 +79,8 @@ def create_chunk(rootdir, chunk_filename, regexps):
include.remove(rootdir)
for filename in reversed(include):
if os.path.isdir(filename):
- os.rmdir(filename)
+ if not os.listdir(filename):
+ os.rmdir(filename)
else:
os.remove(filename)