From 7cb8207e11c408151f0a533752f2a3c8aacd0394 Mon Sep 17 00:00:00 2001 From: Matthieu Gautier Date: Mon, 9 Jan 2017 11:36:23 +0100 Subject: [PATCH] Be sure that the cwd exists before running the command. --- kiwix-build.py | 1 + 1 file changed, 1 insertion(+) diff --git a/kiwix-build.py b/kiwix-build.py index 58c9ed3..916cd91 100755 --- a/kiwix-build.py +++ b/kiwix-build.py @@ -163,6 +163,7 @@ class BuildEnv: return n def run_command(self, command, cwd, context, env=None, input=None): + os.makedirs(cwd, exist_ok=True) with open(context.log_file, 'w') as log: log.write("run command '{}'\n".format(command)) if env: