Do not fail if we try to create an existing directory.

This commit is contained in:
Matthieu Gautier 2018-03-19 12:08:56 +01:00
parent 0da2ffbd4c
commit 841949777d
1 changed files with 4 additions and 1 deletions

View File

@ -84,7 +84,10 @@ def make_archive(project, platform):
archive_dir = NIGHTLY_ARCHIVES_DIR
archive_name = "{}_{}-{}".format(project, platform, postfix)
archive = archive_dir/'{}.tar.gz'.format(archive_name)
archive_dir.mkdir(parents=True)
try:
archive_dir.mkdir(parents=True)
except FileExistsError:
pass
base_bin_dir = BASE_DIR/'INSTALL'/'bin'
with tarfile.open(str(archive), 'w:gz') as arch:
for f in file_to_archives: