diff --git a/nbconvert/exporters/exporter.py b/nbconvert/exporters/exporter.py index e70868f91..2daedf861 100644 --- a/nbconvert/exporters/exporter.py +++ b/nbconvert/exporters/exporter.py @@ -164,7 +164,7 @@ def from_filename(self, filename, resources=None, **kw): resources['metadata'] = ResourcesDict() path, basename = os.path.split(filename) notebook_name = basename[:basename.rfind('.')] - resources['metadata']['name'] = notebook_name + resources['metadata']['title'] = notebook_name resources['metadata']['path'] = path modified_date = datetime.datetime.fromtimestamp(os.path.getmtime(filename)) @@ -277,8 +277,8 @@ def _init_resources(self, resources): resources['metadata'] = new_metadata else: resources['metadata'] = ResourcesDict() - if not resources['metadata']['name']: - resources['metadata']['name'] = 'Notebook' + if not resources['metadata']['title']: + resources['metadata']['title'] = 'Notebook' #Set the output extension resources['output_extension'] = self.file_extension diff --git a/nbconvert/templates/html/full.tpl b/nbconvert/templates/html/full.tpl index 786e2a420..bf336f7fd 100644 --- a/nbconvert/templates/html/full.tpl +++ b/nbconvert/templates/html/full.tpl @@ -8,7 +8,7 @@ {%- block html_head -%} -{{resources['metadata']['name']}} +{{resources['metadata']['title']}} {%- if "widgets" in nb.metadata -%} diff --git a/nbconvert/templates/html/slides_reveal.tpl b/nbconvert/templates/html/slides_reveal.tpl index bd1e06b15..fcc1959b8 100644 --- a/nbconvert/templates/html/slides_reveal.tpl +++ b/nbconvert/templates/html/slides_reveal.tpl @@ -44,7 +44,7 @@ -{{resources['metadata']['name']}} slides +{{resources['metadata']['title']}} slides