From 76b90df4e1c8e72bf0349b78a977375e885a0074 Mon Sep 17 00:00:00 2001 From: Adrian Sampson Date: Mon, 12 Dec 2011 18:31:48 -0800 Subject: [PATCH] fix man-page inclusion if directory already exists --- setup.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/setup.py b/setup.py index f7dabb11a..2e1cc7cae 100755 --- a/setup.py +++ b/setup.py @@ -36,7 +36,10 @@ if 'sdist' in sys.argv: os.chdir(curdir) # Copy resulting manpages. - shutil.copytree(os.path.join(docdir, '_build', 'man'), 'man') + mandir = os.path.join(os.path.dirname(__file__), 'man') + if os.path.exists(mandir): + shutil.rmtree(mandir) + shutil.copytree(os.path.join(docdir, '_build', 'man'), mandir) setup(name='beets', version='1.0b11',