Merge pull request #4544 from theotherjimmy/export-static-files

Export static files from mbed export
pull/4571/head
Sam Grove 2017-06-15 11:18:28 -05:00 committed by GitHub
commit d7c5be26ef
1 changed files with 5 additions and 1 deletions

View File

@ -20,7 +20,7 @@ from os.path import join, abspath, dirname, exists
from os.path import basename, relpath, normpath, splitext
from os import makedirs, walk
import copy
from shutil import rmtree
from shutil import rmtree, copyfile
import zipfile
ROOT = abspath(join(dirname(__file__), ".."))
sys.path.insert(0, ROOT)
@ -349,5 +349,9 @@ def export_project(src_paths, export_path, target, ide, libraries_paths=None,
inc_repos)
else:
zip_export(zip_proj, name, resource_dict, files, inc_repos)
else:
for exported in files:
if not exists(join(export_path, basename(exported))):
copyfile(exported, join(export_path, basename(exported)))
return exporter