UNCLASSIFIED - NO CUI

Skip to content

Update dependency gohugoio/hugo to v0.111.1

renovate requested to merge renovate/gohugoio-hugo-0.x into development

This MR contains the following updates:

Package Type Update Change
gohugoio/hugo ironbank-github minor v0.110.0 -> v0.111.1
gohugoio/hugo minor v0.110.0 -> v0.111.1

Release Notes

gohugoio/hugo

v0.111.1

Compare Source

This fixes the "page" not defined issue in Hugo 0.111.0. eef23a7 @​bep #​10774

v0.111.0

Compare Source

Hugo 0.111.0 is the second Hugo release of the year.

Notable news

Page Fragments

We added the new .Fragments method on Page as part of the Related Content feature refresh (below), but it's plenty useful on its own, and has been long sought after by Hugo users.

It has many uses: Build table of contents, check if a page fragment (heading identifier) exists on a page, check for duplicate heading identifiers, start table of contents from a specific heading identifier. See the Hugo Documentation for more information

Indexing of Page Fragments in Related Content

We have reworked the Related Content API so it's now one method .Related that takes either a Page or an options map. We have also introduced a new type attribute on the index configuration with the new type fragments. See this for details, but to add some weight to the page titles in the Related Content configuration you can do this:

[related]
threshold    = 20
includeNewer = true
toLower      = false
[[related.indices]]
name        = "fragmentrefs"
type        = "fragments"
applyFilter = false
weight = 50

See the Hugo Documentation for more.

Global page func

Note: There was a bug in this release that made this new feature not working, so you need to upgrade to Hugo 0.111.1. We blame it on Go.

Hugo almost always passes a Page as the data context into the top level template (e.g. single.html) (the one exception is the multihost sitemap template). This means that you can access the current page with the . variable in the template.

But when you're deeply nested inside .Render, partial etc., accessing that Page object isn't always practical or possible.

For this reason, Hugo now provides a global page function that you can use to access the current page from anywhere in any template.

{{ page.Title }}

Notes

  • For the Goldmark markdown hander, we now split parse and render for Goldmark. This was motivated by the new fragments support in Related Content, but it has some other side effects: If you only need a page's table of contents, we now skip the rendering step, which makes it faster, but it also means that you can access the page .Fragments structure from everywhere, even in render hooks (271318a @​bep #​10750)
  • tpl/tplimpl: Remove the Google News internal template 66f94b4 @​jmooring
  • Only invoke a given cached partial once 4ef9baf @​bep #​4086 #​9588

Bug fixes

Improvements

Dependency Updates

Documentation

Build Setup


Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever MR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this MR and you won't be reminded about these updates again.


  • If you want to rebase/retry this MR, check this box

This MR has been generated by Renovate Bot.

Merge request reports