From ef422b4f00aaa8c4d5b13f56081d579d59e428b9 Mon Sep 17 00:00:00 2001 From: Oliver Walters Date: Mon, 2 May 2022 10:29:53 +1000 Subject: [PATCH] Ensure output directory has been created --- lib/l10n/collect_translations.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/l10n/collect_translations.py b/lib/l10n/collect_translations.py index 56e3dbe8..f1987e30 100644 --- a/lib/l10n/collect_translations.py +++ b/lib/l10n/collect_translations.py @@ -74,6 +74,10 @@ if __name__ == '__main__': here = os.path.abspath(os.path.dirname(__file__)) + # Ensure the 'collected' output directory exists + output_dir = os.path.join(here, 'collected') + os.makedirs(output_dir, exist_ok=True) + for item in os.listdir(here): # Ignore the output directory