[gtk-doc] mkhtml2: create output-dir if it does not exist



commit 8598188f156cd28df3d061f55614efdb1c4d7162
Author: Stefan Sauer <ensonic users sf net>
Date:   Thu Sep 5 21:36:36 2019 +0200

    mkhtml2: create output-dir if it does not exist

 gtkdoc/mkhtml2.py | 2 ++
 1 file changed, 2 insertions(+)
---
diff --git a/gtkdoc/mkhtml2.py b/gtkdoc/mkhtml2.py
index 0c84483..f54a80d 100644
--- a/gtkdoc/mkhtml2.py
+++ b/gtkdoc/mkhtml2.py
@@ -1849,6 +1849,8 @@ def run(options):
     document = options.args[1]
 
     output_dir = options.output_dir or os.getcmd()
+    if options.output_dir and not os.path.isdir(output_dir):
+        os.mkdir(output_dir)
 
     # TODO: pass options.extra_dir
     sys.exit(main(module, document, output_dir, options.uninstalled, options.src_lang,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]