diff options
Diffstat (limited to 'tools/buildman/builderthread.py')
-rw-r--r-- | tools/buildman/builderthread.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tools/buildman/builderthread.py b/tools/buildman/builderthread.py index 261919f..a9cf68a 100644 --- a/tools/buildman/builderthread.py +++ b/tools/buildman/builderthread.py @@ -12,14 +12,17 @@ import threading import command import gitutil -def Mkdir(dirname): +def Mkdir(dirname, parents = False): """Make a directory if it doesn't already exist. Args: dirname: Directory to create """ try: - os.mkdir(dirname) + if parents: + os.makedirs(dirname) + else: + os.mkdir(dirname) except OSError as err: if err.errno == errno.EEXIST: pass |