Skip to content

Commit a1ef675

Browse files
committed
replace template_path with template_paths
1 parent b767c69 commit a1ef675

File tree

7 files changed

+9
-9
lines changed

7 files changed

+9
-9
lines changed

src/jupyter_contrib_nbextensions/config_scripts/highlight_html_cfg.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
c = get_config() # noqa
99
c.NbConvertApp.export_format = "html"
10-
c.Exporter.template_path = [
10+
c.Exporter.template_paths = [
1111
'.',
1212
jupyter_contrib_nbextensions.nbconvert_support.templates_directory(),
1313
os.path.join(jcnbe_dir, 'nbextensions', 'highlighter')

src/jupyter_contrib_nbextensions/config_scripts/highlight_latex_cfg.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
c = get_config() # noqa
99
c.NbConvertApp.export_format = "latex"
10-
c.Exporter.template_path = [
10+
c.Exporter.template_paths = [
1111
'.',
1212
jupyter_contrib_nbextensions.nbconvert_support.templates_directory(),
1313
os.path.join(jcnbe_dir, 'nbextensions', 'highlighter')

src/jupyter_contrib_nbextensions/install.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ def toggle_install_config(install, user=False, sys_prefix=False,
124124
if logger:
125125
logger.info('-- Configuring nbconvert template path')
126126
# our templates directory
127-
_update_config_list(config, 'Exporter.template_path', [
127+
_update_config_list(config, 'Exporter.template_paths', [
128128
'.',
129129
jupyter_contrib_nbextensions.nbconvert_support.templates_directory(),
130130
], install)

src/jupyter_contrib_nbextensions/migrate.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ def _uninstall_pre_config(logger=None):
128128
config = Config(cm.get(config_basename))
129129
if config and logger:
130130
logger.info('- Removing old config values from {}'.format(config_path))
131-
_update_config_list(config, 'Exporter.template_path', [
131+
_update_config_list(config, 'Exporter.template_paths', [
132132
'.', os.path.join(jupyter_data_dir(), 'templates'),
133133
], False)
134134
_update_config_list(config, 'Exporter.preprocessors', [

src/jupyter_contrib_nbextensions/nbconvert_support/exporter_inliner.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@ def default_config(self):
3939
templates_directory)
4040
contrib_templates_dir = templates_directory()
4141

42-
template_path = c.TemplateExporter.setdefault('template_path', [])
43-
if contrib_templates_dir not in template_path:
44-
template_path.append(contrib_templates_dir)
42+
template_paths = c.TemplateExporter.setdefault('template_paths', [])
43+
if contrib_templates_dir not in template_paths:
44+
template_paths.append(contrib_templates_dir)
4545

4646
return c

src/jupyter_contrib_nbextensions/nbconvert_support/toc2.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ def default_config(self):
5555
templates_directory)
5656
c.merge(super(TocExporter, self).default_config)
5757

58-
c.TemplateExporter.template_path = [
58+
c.TemplateExporter.template_paths = [
5959
'.',
6060
templates_directory(),
6161
]

src/jupyter_contrib_nbextensions/nbextensions/runtools/readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ print(templates_directory())
7878
```
7979

8080
The template needs to be in a path where nbconvert can find it. This can be your local path or specified in
81-
`jupyter_nbconvert_config` or `jupyter_notebook_config` as `c.Exporter.template_path`, see [Jupyter docs](https://jupyter-notebook.readthedocs.io/en/latest/config.html).
81+
`jupyter_nbconvert_config` or `jupyter_notebook_config` as `c.Exporter.template_paths`, see [Jupyter docs](https://jupyter-notebook.readthedocs.io/en/latest/config.html).
8282

8383
For HTML export a template is provided as `nbextensions.tpl` in the `jupyter_contrib_nbextensions` templates directory. Alternatively you can create your own template:
8484
```

0 commit comments

Comments
 (0)