diff options
author | Lars Wirzenius <liw@liw.fi> | 2011-08-24 17:19:35 +0100 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2011-08-24 17:19:35 +0100 |
commit | c7d59ec44617941534ad62d48c744e22d3f2bb38 (patch) | |
tree | 52cd81e17aa74cdc7b88930c4d2fd2b676b013c3 | |
parent | 01e098343416ba2451a518fe5ac375ca83ac3aad (diff) | |
download | obnam-c7d59ec44617941534ad62d48c744e22d3f2bb38.tar.gz |
Remove ./build if it exists, in setup.py clean.
-rw-r--r-- | setup.py | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -21,6 +21,7 @@ from distutils.command.build import build from distutils.command.clean import clean import glob import os +import shutil import subprocess class GenerateManpage(build): @@ -46,6 +47,8 @@ class CleanMore(clean): os.remove(x) self.remove_pyc('obnamlib') self.remove_pyc('test-plugins') + if os.path.isdir('build'): + shutil.rmtree('build') def remove_pyc(self, rootdir): for dirname, subdirs, basenames in os.walk(rootdir): |