Update to Hugo 0.53 and remove all .Site references (#12079)
* Remove all .Site variable references * Update Hugo version in Travis CI config and Makefile
This commit is contained in:
committed by
Kubernetes Prow Robot
parent
2ccb5d61c6
commit
c6dd35ba51
@@ -10,7 +10,7 @@
|
||||
{{ define "docs-browse-section" }}
|
||||
{{ $pages := .page.Pages }}
|
||||
{{ $sections := .page.Sections }}
|
||||
{{ with $.ctx.Site.Params.language_alternatives }}
|
||||
{{ with site.Params.language_alternatives }}
|
||||
{{ range . }}
|
||||
{{ with (where $.page.Translations ".Lang" . ) }}
|
||||
{{ $p := index . 0 }}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{{ $glossaryBundle := .Site.GetPage "page" "docs/reference/glossary" }}
|
||||
{{ $glossaryBundle := site.GetPage "page" "docs/reference/glossary" }}
|
||||
{{- if $glossaryBundle -}}
|
||||
{{ $pages := $glossaryBundle.Resources.ByType "page" }}
|
||||
{{- range $.Site.Params.language_alternatives -}}
|
||||
{{- range site.Params.language_alternatives -}}
|
||||
{{- with (where $glossaryBundle.Translations ".Lang" . ) -}}
|
||||
{{ $p := (index . 0) }}
|
||||
{{ $pages = $pages | lang.Merge ($p.Resources.ByType "page") }}
|
||||
@@ -9,5 +9,5 @@
|
||||
{{ end }}
|
||||
{{- $.Scratch.Set "glossary_items" $pages -}}
|
||||
{{- else -}}
|
||||
{{- errorf "[%s] Glossary Bundle not found for language. Create at least an index.md file inside docs/reference/glossary" .Page.Site.Language.Lang -}}
|
||||
{{- errorf "[%s] Glossary Bundle not found for language. Create at least an index.md file inside docs/reference/glossary" site.Language.Lang -}}
|
||||
{{- end -}}
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
{{ $p := . }}
|
||||
{{ .Scratch.Set "section" .CurrentSection }}
|
||||
{{ .Scratch.Set "sectionFound" false }}
|
||||
{{ $docs := .Site.GetPage "section" "docs" }}
|
||||
{{ $docs := site.GetPage "section" "docs" }}
|
||||
{{ if ne .CurrentSection $docs }}
|
||||
{{ range $docs.Sections }}
|
||||
{{ if not ($.Scratch.Get "sectionFound") }}
|
||||
@@ -21,4 +21,4 @@
|
||||
{{ partialCached "tree.html" $section $section.RelPermalink }}
|
||||
</div> <!-- /pi-accordion -->
|
||||
<button class="push-menu-close-button" onclick="kub.toggleToc()"></button>
|
||||
</div> <!-- /docsToc -->
|
||||
</div> <!-- /docsToc -->
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{{ $p := . }}
|
||||
{{ $home := .Site.Home }}
|
||||
{{ $docs := .Site.GetPage "section" "docs" }}
|
||||
{{ $home := site.Home }}
|
||||
{{ $docs := site.GetPage "section" "docs" }}
|
||||
{{ $menuSections := (where $docs.Sections ".Params.main_menu" true) }}
|
||||
{{ range $menuSections }}
|
||||
{{ if $p.IsDescendant . }}
|
||||
|
||||
Reference in New Issue
Block a user