fix: Hugo language related deprecation (v0.158.0+) (#1334)
* language related deprecation fix Reference: https://github.com/gohugoio/hugo/releases/tag/v0.158.0 .Site.LanguageCode -> .Site.Language.Locale .Language.LanguageDirection -> .Language.Direction .Language.LanguageCode -> .Language.Locale Also, in the configuration hugo.toml, the user should change `languageCode` to `locale`. * Update languageCode to locale in configuration * fix(languages): update languageName to label in languages.toml * .Language.LanguageName -> .Language.Label * .Language.Lang -> .Language.Name --------- Co-authored-by: Jimmy Cai <jimmy@cai.im>
This commit is contained in:
+1
-1
@@ -30,7 +30,7 @@
|
||||
<link>{{ .Permalink }}</link>
|
||||
<description>Recent content {{ if ne .Title .Site.Title }}{{ with .Title }}in {{ . }} {{ end }}{{ end }}on {{ .Site.Title }}</description>
|
||||
<generator>Hugo -- gohugo.io</generator>
|
||||
<language>{{ site.Language.LanguageCode }}</language>{{ with $authorEmail }}
|
||||
<language>{{ site.Language.Locale }}</language>{{ with $authorEmail }}
|
||||
<managingEditor>{{.}}{{ with $authorName }} ({{ . }}){{ end }}</managingEditor>{{ end }}{{ with $authorEmail }}
|
||||
<webMaster>{{ . }}{{ with $authorName }} ({{ . }}){{ end }}</webMaster>{{ end }}{{ with .Site.Copyright }}
|
||||
<copyright>{{ . }}</copyright>{{ end }}{{ if not .Date.IsZero }}
|
||||
|
||||
Reference in New Issue
Block a user