From 4f6ab6583de771e74874e72ec88c7fe09a5d4b6b Mon Sep 17 00:00:00 2001 From: Matthias Bussonnier Date: Sun, 3 Dec 2023 10:32:09 -0800 Subject: [PATCH] Allow to load config from env. (#2075) --- nbconvert/nbconvertapp.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/nbconvert/nbconvertapp.py b/nbconvert/nbconvertapp.py index 78a0724ea..0b2a68f50 100755 --- a/nbconvert/nbconvertapp.py +++ b/nbconvert/nbconvertapp.py @@ -357,6 +357,8 @@ def initialize(self, argv=None): self.init_syspath() super().initialize(argv) + if hasattr(self, "load_config_environ"): + self.load_config_environ() self.init_notebooks() self.init_writer() self.init_postprocessor() @@ -655,6 +657,8 @@ def initialize(self, argv=None): self.config.QtPDFExporter.paginate = False super().initialize(argv) + if hasattr(self, "load_config_environ"): + self.load_config_environ() @default("export_format") def _default_export_format(self):