combo-layer: Make directories only if they don't exisit yet
(From OE-Core rev: 24188967209bad291545909ddb89af35ab3f6021) Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
bede5a4180
commit
51cccb7fb9
|
@ -194,7 +194,8 @@ def action_init(conf, args):
|
||||||
dest_dir = repo['dest_dir']
|
dest_dir = repo['dest_dir']
|
||||||
if dest_dir and dest_dir != ".":
|
if dest_dir and dest_dir != ".":
|
||||||
extract_dir = os.path.join(os.getcwd(), dest_dir)
|
extract_dir = os.path.join(os.getcwd(), dest_dir)
|
||||||
os.makedirs(extract_dir)
|
if not os.path.exists(extract_dir):
|
||||||
|
os.makedirs(extract_dir)
|
||||||
else:
|
else:
|
||||||
extract_dir = os.getcwd()
|
extract_dir = os.getcwd()
|
||||||
file_filter = repo.get('file_filter', "")
|
file_filter = repo.get('file_filter', "")
|
||||||
|
@ -354,7 +355,8 @@ def action_update(conf, args):
|
||||||
|
|
||||||
import uuid
|
import uuid
|
||||||
patch_dir = "patch-%s" % uuid.uuid4()
|
patch_dir = "patch-%s" % uuid.uuid4()
|
||||||
os.mkdir(patch_dir)
|
if not os.path.exists(patch_dir):
|
||||||
|
os.mkdir(patch_dir)
|
||||||
|
|
||||||
# Step 1: update the component repos
|
# Step 1: update the component repos
|
||||||
if conf.nopull:
|
if conf.nopull:
|
||||||
|
|
Loading…
Reference in New Issue