From 7125ad401ad043e46262afc7eca8dceb6d54bb9e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Erik=20Pedersen?= Date: Fri, 26 Jan 2024 08:11:52 +0100 Subject: [PATCH] Squashed 'docs/' changes from 4dd2d6415..3b1a8579d 3b1a8579d Update theme b1f04fd47 params: Adjust the twitter handle 2c8ba029f Fix typo 4421e46ec Update Where.md 5f9fec6a5 Update glossary.md fb16945cf collections.Where - Clarify description of "collection" 4d6d7018b Update Include.md - improve return statement example 037151073 Update IncludeCached - improve return statement example b053fa09c Improve return types f7d615267 Describe minimum required Windows version e97762b2a Update front matter in math.Sub 9e4d03a79 Fix data.GetJSON examples 9029ee123 Update spellcheck GitHub Action c852fe421 Add version verification step to quick start guide 8fafca49c Correct front matter example b412fdf65 Fix closing tag in notes docs 9a64d9579 Add hreflang Tag to Translation Link example 2d2a82101 Fix inverted examples in Permalink and RelPermalink ff3e67e3f Correct spelling 3904b72e3 Fix documentation contribution steps enumeration 348fd3c02 Fix some typos in the content summaries page a5823459a Fix two links, one to bonsai.io and one to digital.gov c36978686 Fix typo 0ee3ff44f Vendor theme 6b0a9b75d Fix typo 44e4cb5c6 Fix typos 815071742 Update min Go version to build from source 192d14df5 Fix typo e4a18946e Miscellaneous corrections f12b7b74e netlify: Hugo 0.121.2 97dbc1ea1 Merge branch 'tempv0.121.2' dc1c0aeeb Add cache note to resources.Concat a8d1a6020 Correct return type eca22e97c Fix front matter 7de247a03 Correct return type 5058bc520 collections.Seq: Specify max slice size e24d81a4b Fix typo on FAQ page ff8cf5a88 Correct 'related' front matter values 88b21fae0 Adjust deprecation handling f7e19a25b Update terminology on shortcode templates page 01e10942a Adjust formatting 6ed2e19c2 tpl/math: Add math.Rand template function b494a8d8d Update js.md 6d78035f4 Add interval description to glossary (#2378) f9b612b64 Templates Lookup Order: Add missing parenthesis 741ab1bb2 Show vendorClosest in module default config eb8cb878f Fix Babel headings cdcdfc8e8 Change project name in Codeowners example f31fe0d63 Update link to image filters 9dee1ee0e Update Solus installation instructions 716636fee Add TOC to collections.Sort f7c64143c Update collections.Sort 4b8f6b991 Add id attributes to Scratch and Store methods 2a1adea79 Add id attributes to GitInfo, File, and Resources methods b12d9cb8f Add Alpine Linux installation instructions dfbebeec7 Change writeStats to buildStats 175b8aac8 resources/images: Create AutoOrient image filter ba8e05c31 Update img shortcode 7fc15a6cc Fix default value of pluralizeListTitles a0be4fd8a Add Comentario to available comment engines 71aa7d8ab Update GitInfo.md 348441491 EXIF: describe applicable image types 743497eda Disable TOC for lang.Translate b3b1df75d Describe lang.Translate fallback behavior a6d9c362c Categorize CLI commands to improve search results 08cc2da4b Document canonical config for enabling inline shortcodes 8945be9c6 Update description of the humanize ordinal conversion b8b4ccb6f Fix grammatical error f53f9f936 Fix description of strings.HasSuffix cdbe19b5b Update Params.md e00c4eea2 Reformat site config descriptions 6f50c0755 Enumerate root configuration keys 1f2e7b9b2 Use canonical key when documenting menu configs 7d5a13d8d Update images.Text filter 315d2f8c3 Add math.Counter example to warnf 8ed9cdaa9 Miscellaneous edits 2bda491eb Fix front matter example 5c5bbbe3a netlify: Bump to Hugo 0.121.1 ed08f5943 Update Gentoo installation instructions e4eb48457 Miscellaneous edits 8c3700d12 netlify: Bump to Hugo 0.121.0 1bb5a377f Merge branch 'tempv0.121.0' 8cba89504 Improve where function 0dfc00b0f docs: Regen docshelper 028076a66 Fix link to Gentoo package 52d2db4ff Fix typo 120025c19 Improve Gentooo installation instructions 0c31a4b45 Update GitHub hosting workflow example dee99c36a Defend against missing aliases in quick-reference shortcode d305278f1 Add Gentoo installation instructions be98a37e1 docs: Adjust last merge from docs repository a703dab53 docs: Regen docs helper 2e9c3532f Merge commit '35dec7c96f7ee3eb17dd444f7067f0c776fb56ae' f57fdb44b deps: Update github.com/tdewolff/minify/v2 v2.20.7 => v2.20.8 50cad5e38 tpl/transform: Add transform.XMLEscape template function git-subtree-dir: docs git-subtree-split: 3b1a8579d2e032c1aab8a74d4cf63849ba11e7a8 --- .cspell.json | 5 +- .github/workflows/spellcheck.yml | 2 +- .markdownlint.yaml | 1 + .../gohugoioTheme/assets/js/menutoggle.js | 2 +- .../layouts/_default/_markup/render-link.html | 2 +- .../layouts/partials/social-follow.html | 30 +- .../layouts/shortcodes/deprecated-in.html | 2 +- .../gohugoioTheme/layouts/shortcodes/img.html | 15 +- .../layouts/shortcodes/include.html | 2 +- .../shortcodes/list-pages-in-section.html | 2 +- .../layouts/shortcodes/new-in.html | 49 +- .../layouts/shortcodes/quick-reference.html | 10 +- _vendor/modules.txt | 2 +- .../examples/landscape-exif-orientation-5.jpg | Bin 0 -> 38639 bytes config/_default/params.toml | 4 +- content/en/content-management/comments.md | 4 +- .../image-processing/index.md | 2 +- content/en/content-management/menus.md | 38 +- content/en/content-management/multilingual.md | 23 +- content/en/content-management/summaries.md | 2 +- content/en/contribute/documentation.md | 18 +- content/en/functions/collections/Append.md | 3 +- content/en/functions/collections/Apply.md | 7 +- content/en/functions/collections/Delimit.md | 5 - .../en/functions/collections/Dictionary.md | 5 +- content/en/functions/collections/First.md | 1 + content/en/functions/collections/Group.md | 6 +- content/en/functions/collections/In.md | 1 - .../en/functions/collections/IndexFunction.md | 6 +- content/en/functions/collections/IsSet.md | 4 - .../en/functions/collections/NewScratch.md | 43 +- content/en/functions/collections/Querify.md | 5 +- content/en/functions/collections/Reverse.md | 11 +- content/en/functions/collections/Seq.md | 20 +- content/en/functions/collections/Shuffle.md | 9 +- content/en/functions/collections/Slice.md | 10 +- content/en/functions/collections/Sort.md | 44 +- content/en/functions/collections/SymDiff.md | 10 +- content/en/functions/collections/Union.md | 10 +- content/en/functions/collections/Uniq.md | 10 +- content/en/functions/collections/Where.md | 52 +- content/en/functions/crypto/FNV32a.md | 4 +- content/en/functions/data/GetJSON.md | 9 +- content/en/functions/fmt/Warnf.md | 11 + content/en/functions/global/page.md | 2 +- content/en/functions/go-template/range.md | 2 +- content/en/functions/go-template/with.md | 2 +- content/en/functions/images/AutoOrient.md | 52 ++ content/en/functions/images/Text.md | 6 +- content/en/functions/inflect/Humanize.md | 2 +- content/en/functions/lang/Translate.md | 17 + content/en/functions/math/Rand.md | 46 ++ content/en/functions/math/Sub.md | 1 + content/en/functions/openapi3/Unmarshal.md | 2 +- content/en/functions/partials/Include.md | 2 +- .../en/functions/partials/IncludeCached.md | 2 +- content/en/functions/resources/Concat.md | 15 +- .../functions/resources/ExecuteAsTemplate.md | 10 +- content/en/functions/resources/FromString.md | 10 +- content/en/functions/resources/Minify.md | 2 +- content/en/functions/resources/ToCSS.md | 8 +- content/en/functions/safe/HTMLAttr.md | 2 +- content/en/functions/safe/URL.md | 2 +- .../en/functions/strings/FindRESubmatch.md | 2 +- content/en/functions/strings/FindRe.md | 2 +- content/en/functions/strings/HasSuffix.md | 2 +- content/en/functions/transform/XMLEscape.md | 40 ++ content/en/getting-started/configuration.md | 493 ++++++++---------- content/en/getting-started/glossary.md | 14 + content/en/getting-started/quick-start.md | 29 +- .../hosting-on-github/index.md | 6 +- .../hosting-on-gitlab.md | 4 +- .../hosting-on-netlify.md | 4 +- content/en/hugo-modules/configuration.md | 31 +- content/en/hugo-modules/use-modules.md | 2 +- content/en/hugo-pipes/babel.md | 6 +- content/en/hugo-pipes/js.md | 2 +- content/en/hugo-pipes/minification.md | 2 +- .../_common/04-build-from-source.md | 2 +- content/en/installation/_common/homebrew.md | 2 +- content/en/installation/bsd.md | 6 +- content/en/installation/linux.md | 49 +- content/en/installation/macos.md | 2 +- content/en/installation/windows.md | 11 +- content/en/methods/menu-entry/Children.md | 6 +- content/en/methods/menu-entry/HasChildren.md | 6 +- content/en/methods/menu-entry/Identifier.md | 4 +- content/en/methods/menu-entry/KeyName.md | 4 +- content/en/methods/menu-entry/Page.md | 8 +- content/en/methods/menu-entry/Params.md | 8 +- content/en/methods/menu-entry/Parent.md | 7 +- .../en/methods/menu-entry/_common/pre-post.md | 4 +- content/en/methods/menu/ByName.md | 6 +- content/en/methods/menu/ByWeight.md | 6 +- content/en/methods/menu/Limit.md | 6 +- content/en/methods/menu/Reverse.md | 6 +- content/en/methods/page/AllTranslations.md | 15 +- content/en/methods/page/CodeOwners.md | 2 +- content/en/methods/page/CurrentSection.md | 2 +- content/en/methods/page/File.md | 50 +- content/en/methods/page/FirstSection.md | 2 +- content/en/methods/page/Fragments.md | 4 +- content/en/methods/page/GetPage.md | 2 +- content/en/methods/page/GitInfo.md | 42 +- content/en/methods/page/Next.md | 2 +- content/en/methods/page/NextInSection.md | 2 +- content/en/methods/page/Page.md | 2 +- content/en/methods/page/Params.md | 4 +- content/en/methods/page/Parent.md | 2 +- content/en/methods/page/Permalink.md | 2 +- content/en/methods/page/Prev.md | 2 +- content/en/methods/page/PrevInSection.md | 2 +- content/en/methods/page/RelPermalink.md | 2 +- content/en/methods/page/Resources.md | 20 +- content/en/methods/page/Store.md | 37 +- content/en/methods/page/Translations.md | 11 +- .../methods/page/_common/scratch-methods.md | 37 +- content/en/methods/pages/Next.md | 2 +- content/en/methods/pages/Prev.md | 2 +- content/en/methods/resource/Exif.md | 4 +- content/en/methods/shortcode/Page.md | 2 +- content/en/methods/site/DisqusShortname.md | 5 +- content/en/methods/site/GetPage.md | 2 +- content/en/methods/site/GoogleAnalytics.md | 5 +- content/en/methods/site/Home.md | 2 +- content/en/methods/site/IsDevelopment.md | 9 +- content/en/methods/site/IsServer.md | 9 +- content/en/methods/site/Menus.md | 10 +- .../ordered-taxonomy-element-methods.md | 2 +- content/en/showcase/digitalgov/index.md | 2 +- content/en/templates/internal.md | 1 + content/en/templates/lookup-order.md | 2 +- content/en/templates/shortcode-templates.md | 11 +- content/en/tools/search.md | 4 +- content/en/troubleshooting/deprecation.md | 10 +- content/en/troubleshooting/faq.md | 2 +- content/en/troubleshooting/performance.md | 2 +- data/docs.yaml | 47 +- go.mod | 2 +- go.sum | 6 +- hugo.toml | 5 + layouts/shortcodes/new-in.html | 36 -- netlify.toml | 2 +- 143 files changed, 1089 insertions(+), 809 deletions(-) create mode 100644 assets/images/examples/landscape-exif-orientation-5.jpg create mode 100644 content/en/functions/images/AutoOrient.md create mode 100644 content/en/functions/math/Rand.md create mode 100644 content/en/functions/transform/XMLEscape.md delete mode 100644 layouts/shortcodes/new-in.html diff --git a/.cspell.json b/.cspell.json index ae469d646..1c386ee29 100644 --- a/.cspell.json +++ b/.cspell.json @@ -7,8 +7,10 @@ "flagWords": [ "alot", "hte", + "langauge", "reccommend", - "seperate" + "seperate", + "teh" ], "ignorePaths": [ "**/emojis.md", @@ -69,6 +71,7 @@ "transpile", "transpiles", "unmarshal", + "unmarshals", "unmarshaling", "# ----------------------------------------------------------------------", "# cspell: ignore foreign language words", diff --git a/.github/workflows/spellcheck.yml b/.github/workflows/spellcheck.yml index a650f153c..86f8f53a5 100644 --- a/.github/workflows/spellcheck.yml +++ b/.github/workflows/spellcheck.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - uses: streetsidesoftware/cspell-action@v4 + - uses: streetsidesoftware/cspell-action@v5 with: check_dot_files: false files: content/**/*.md diff --git a/.markdownlint.yaml b/.markdownlint.yaml index 58f84dc67..d9c2c5a67 100644 --- a/.markdownlint.yaml +++ b/.markdownlint.yaml @@ -1,5 +1,6 @@ # https://github.com/DavidAnson/markdownlint/blob/main/doc/Rules.md +MD001: false MD002: false MD003: false MD004: false diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/assets/js/menutoggle.js b/_vendor/github.com/gohugoio/gohugoioTheme/assets/js/menutoggle.js index d0e645385..40bda0ce9 100644 --- a/_vendor/github.com/gohugoio/gohugoioTheme/assets/js/menutoggle.js +++ b/_vendor/github.com/gohugoio/gohugoioTheme/assets/js/menutoggle.js @@ -1,4 +1,4 @@ -// Grab any element that has the 'js-toggle' class and add an event listner for the toggleClass function +// Grab any element that has the 'js-toggle' class and add an event listener for the toggleClass function var toggleBtns = document.getElementsByClassName('js-toggle') for (var i = 0; i < toggleBtns.length; i++) { toggleBtns[i].addEventListener('click', toggleClass, false) diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/_default/_markup/render-link.html b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/_default/_markup/render-link.html index 7b3d58c2d..5583d53d7 100644 --- a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/_default/_markup/render-link.html +++ b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/_default/_markup/render-link.html @@ -201,7 +201,7 @@ either of these shortcodes in conjunction with this render hook. Validates the fragment portion of a link destination. @context {string} contentPath The page containing the link. - @context {srting} errorLevel The error level when unable to resolve destination; ignore (default), warning, or error. + @context {string} errorLevel The error level when unable to resolve destination; ignore (default), warning, or error. @context {page} page The page corresponding to the link destination @context {struct} parsedURL The link destination parsed by urls.Parse. @context {string} renderHookName The name of the render hook. diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/partials/social-follow.html b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/partials/social-follow.html index ce16953c8..7451c15d6 100644 --- a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/partials/social-follow.html +++ b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/partials/social-follow.html @@ -1,9 +1,21 @@ -{{/* - Disable Twitter for now as we lost access to the account. - with site.Params.social.twitter }} - - {{ partial "svg/twitter.svg" (dict "size" "32px") }} - -{{ end */}} - gohugoio - Star + + {{ partial "svg/twitter.svg" (dict "size" "32px") }} + +gohugoio +Star diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/deprecated-in.html b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/deprecated-in.html index cab85541d..7219d7f54 100644 --- a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/deprecated-in.html +++ b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/deprecated-in.html @@ -5,7 +5,7 @@ {{ $href := printf "https://github.com/gohugoio/hugo/releases/tag/%s" $version }} diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/img.html b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/img.html index ea5b6de1d..50d4da9ed 100644 --- a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/img.html +++ b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/img.html @@ -100,7 +100,7 @@ Renders the given image using the given filter, if any. "fontSize" 64 "lineHeight" 1.2 "fontColor" "#ffffff" - "fontPath" "https://github.com/google/fonts/raw/main/apache/roboto/static/Roboto-Regular.ttf" + "fontPath" "https://github.com/google/fonts/raw/main/ofl/lato/Lato-Regular.ttf" }} {{- /* Get and validate parameters. */}} @@ -119,9 +119,10 @@ Renders the given image using the given filter, if any. {{- end }} {{- $validFilters := slice - "brightness" "colorbalance" "colorize" "contrast" "gamma" "gaussianblur" - "grayscale" "hue" "invert" "none" "opacity" "overlay" "padding" "pixelate" - "process" "saturation" "sepia" "sigmoid" "text" "unsharpmask" + "autoorient" "brightness" "colorbalance" "colorize" "contrast" "gamma" + "gaussianblur" "grayscale" "hue" "invert" "none" "opacity" "overlay" + "padding" "pixelate" "process" "saturation" "sepia" "sigmoid" "text" + "unsharpmask" }} {{- with $filter }} @@ -157,7 +158,11 @@ Renders the given image using the given filter, if any. {{- /* Create filter. */}} {{- $f := "" }} {{- $ctx := dict "filter" $filter "args" $filterArgs "name" .Name "position" .Position }} -{{- if eq $filter "brightness" }} +{{- if eq $filter "autoorient" }} + {{- $ctx = merge $ctx (dict "argsRequired" 0) }} + {{- template "validate-arg-count" $ctx }} + {{- $f = images.AutoOrient }} +{{- else if eq $filter "brightness" }} {{- $ctx = merge $ctx (dict "argsRequired" 1) }} {{- template "validate-arg-count" $ctx }} {{- $filterArgs = apply $filterArgs "float" "." }} diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/include.html b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/include.html index a13dd756a..9ad6e4ecb 100644 --- a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/include.html +++ b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/include.html @@ -3,7 +3,7 @@ Renders the page using the RenderShortcode method on the Page object. You must call this shortcode using the {{% %}} notation. -@param {string} (postional parameter 0) The path to the page, relative to the content directory. +@param {string} (positional parameter 0) The path to the page, relative to the content directory. @returns template.HTML @example {{% include "functions/_common/glob-patterns" %}} diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/list-pages-in-section.html b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/list-pages-in-section.html index 07a41d613..73e7f85a9 100644 --- a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/list-pages-in-section.html +++ b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/list-pages-in-section.html @@ -1,5 +1,5 @@ {{- /* -Renders a desciption list of the pages in the given section. +Renders a description list of the pages in the given section. Render a subset of the pages in the section by specifying a predefined filter, and whether to include those pages. diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/new-in.html b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/new-in.html index 9236cf2bc..e22a91f3d 100644 --- a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/new-in.html +++ b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/new-in.html @@ -1,13 +1,36 @@ -{{ $version := .Get 0 }} -{{ if not $version }} - {{ errorf "Missing version in new-in shortcode " }} -{{ end }} -{{ $version = $version | strings.TrimPrefix "v" }} - +{{- /* +Renders a "new in" button indicating the version in which a feature was added. + +When comparing the current version to the specified version, the "new in" +button will be hidden if any of the following conditions is true: + +- The major version difference exceeds the majorVersionDiffThreshold +- The minor version difference exceeds the minorVersionDiffThreshold + +@param {string} version The semantic version string, with or without a leading v. +@returns {template.HTML} + +@example {{< new-in 0.100.0 >}} +*/}} + +{{- /* Set defaults. */}} +{{- $majorVersionDiffThreshold := 0 }} +{{- $minorVersionDiffThreshold := 30 }} +{{- $displayExpirationWarning := true }} + +{{- /* Render. */}} +{{- with $version := .Get 0 | strings.TrimPrefix "v" }} + {{- $majorVersionDiff := sub (index (split hugo.Version ".") 0 | int) (index (split $version ".") 0 | int) }} + {{- $minorVersionDiff := sub (index (split hugo.Version ".") 1 | int) (index (split $version ".") 1 | int) }} + {{- if or (gt $majorVersionDiff $majorVersionDiffThreshold) (gt $minorVersionDiff $minorVersionDiffThreshold) }} + {{- if $displayExpirationWarning }} + {{- warnf "This call to the %q shortcode should be removed: %s. The button is now hidden because the specified version (%s) is older than the display threshold." $.Name $.Position $version }} + {{- end }} + {{- else }} + + {{- end }} +{{- else }} + {{- errorf "The %q shortcode requires a positional parameter (version). See %s" .Name .Position }} +{{- end -}} diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/quick-reference.html b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/quick-reference.html index 250bfc065..fc53c93bd 100644 --- a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/quick-reference.html +++ b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/shortcodes/quick-reference.html @@ -1,5 +1,5 @@ {{/* -Renders the child sections of the given top-level section, listing each childs's immediate descendants. +Renders the child sections of the given top-level section, listing each child's immediate descendants. @param {string} section The top-level section to render. @returns template.HTML @@ -11,7 +11,7 @@ Renders the child sections of the given top-level section, listing each childs's {{ with .Get "section" }} {{ $section = . }} {{ else }} - {{ errorf "The %q shortcodes requires a 'section' parameter. See %s" .Name .Postion }} + {{ errorf "The %q shortcodes requires a 'section' parameter. See %s" .Name .Position }} {{ end }} {{/* Do not change the markdown indentation, and do not remove blank lines. */}} @@ -24,7 +24,9 @@ Renders the child sections of the given top-level section, listing each childs's {{ range .Pages }} {{ $aliases := "" }} {{ if eq .Section "functions" }} - {{ $aliases = delimit .Params.action.aliases " or " }} + {{ with .Params.action.aliases }} + {{ $aliases = delimit . " or " }} + {{ end }} {{ end }} [{{ .LinkTitle }}]({{ .RelPermalink }}) {{ with $aliases }}({{ . }}){{ end }} @@ -33,5 +35,5 @@ Renders the child sections of the given top-level section, listing each childs's {{ end }} {{ end }} {{ else }} - {{ errorf "The %q shortcodes was unable to find the %q section. See %s" .Name $section .Postion }} + {{ errorf "The %q shortcodes was unable to find the %q section. See %s" .Name $section .Position }} {{ end }} diff --git a/_vendor/modules.txt b/_vendor/modules.txt index 7a692e0ce..a7e53c51c 100644 --- a/_vendor/modules.txt +++ b/_vendor/modules.txt @@ -1 +1 @@ -# github.com/gohugoio/gohugoioTheme v0.0.0-20231111235806-77931ac4875e +# github.com/gohugoio/gohugoioTheme v0.0.0-20240125093153-bea12fdc0b15 diff --git a/assets/images/examples/landscape-exif-orientation-5.jpg b/assets/images/examples/landscape-exif-orientation-5.jpg new file mode 100644 index 0000000000000000000000000000000000000000..ad64835eb2209c960dfb21c4437fa72754cd98d2 GIT binary patch literal 38639 zcmb4qWl$VJ*Y3jN!6mS`Y;Xwf?iSqL-95Nla00kDC@6r`#|3!b0vL;XTA2d?-@XB80RR9302T@p z0Q``k0I(k!{(tfh832%hBKTif8H)OU%0L4E&{+Q?|EJXdO&^y3`^7gv7)YR4lX4uKD4$S3sHh-zFfo|@|2w^R127Pv;-NKxP~-q;3@9K5)O#O* z0Ps>5ElL;gNKHPf(8O$FfhrOVTG~Cm5kt= z0Va%$iyM3j4`E?Bp4z{Z!Kor6SG5|eVLXTAipv8$??hSYx8!iV~goB!9*hb)Y=NyoRX%|f5E+%68icFQ;ri#iAQ zqsTl&aaAb}n*(P^o%*;Y2WFUUv;t8T+B!0VhUwZk=uPdukP!}riWQxslp$hVZy+7X z_Z)&GEpJ)P1XiPs|5Y2pyc>fdjxQ(s-y4jy)SW<$$+ru2`mTgJ zl5L-=?Y62$A7Rfe*KOmj7XgDq*_(4dKM-H*WNSv)(Jy^HP})Ua=rvJEY&x67-y`=b z>vkvbce?L7pjMtrFn=T7xQnk=w9_goJC4EFf-G%}7d*ZD@Li=%`BrZ8Uvlx&vpF^n z1@nl-`X+{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2j(k9z5j z2sIO}NBg!TwNVk0IE&XIj{6Fp?swj)bqLP9cBwZ5PxYxz#*G7a$lvm>P#Lqgdi6xQ HT0j5UC*8$J literal 0 HcmV?d00001 diff --git a/config/_default/params.toml b/config/_default/params.toml index b41679c61..dddd53b5b 100644 --- a/config/_default/params.toml +++ b/config/_default/params.toml @@ -21,7 +21,7 @@ flex_box_interior_classes = "flex-auto w-100 w-40-l mr3 mb3 bg-white ba b--moon- #sidebar_direction = "sidebar_left" [social] -twitter = "GoHugoIO" + twitter = "GoHugoIOv2" [render_hooks.link] -errorLevel = 'warning' # ignore (default), warning, or error (fails the build) + errorLevel = 'warning' # ignore (default), warning, or error (fails the build) diff --git a/content/en/content-management/comments.md b/content/en/content-management/comments.md index 5f2f9660b..6e58b36e4 100644 --- a/content/en/content-management/comments.md +++ b/content/en/content-management/comments.md @@ -25,7 +25,8 @@ Hugo comes with all the code you need to load Disqus into your templates. Before Disqus comments require you set a single value in your [site's configuration file][configuration] like so: {{< code-toggle file=hugo >}} -disqusShortname = "yourDisqusShortname" +[services.disqus] +shortname = 'your-disqus-shortname' {{}} For many websites, this is enough configuration. However, you also have the option to set the following in the [front matter] of a single content file: @@ -47,6 +48,7 @@ Disqus has its own [internal template](/templates/internal/#disqus) available, t These are some alternatives to Disqus: * [Cactus Comments](https://cactus.chat/docs/integrations/hugo/) (Open Source, Matrix appservice, Docker install) +* [Comentario](https://gitlab.com/comentario/comentario) (Open Source, self-hosted, Go/Angular, run locally, in Docker or Kubernetes) * [Commento](https://commento.io/) (Open Source, available as a service, local install, or docker image) * [Giscus](https://giscus.app/) (Open source, comments system powered by GitHub Discussions) * [Graph Comment](https://graphcomment.com/) diff --git a/content/en/content-management/image-processing/index.md b/content/en/content-management/image-processing/index.md index 511365700..9a4f55da1 100644 --- a/content/en/content-management/image-processing/index.md +++ b/content/en/content-management/image-processing/index.md @@ -505,7 +505,7 @@ hugo --gc [mounted]: /hugo-modules/configuration#module-configuration-mounts [page bundle]: /content-management/page-bundles [`lang.FormatNumber`]: /functions/lang/formatnumber -[filters]: /functions/images +[filters]: /functions/images/filter/#image-filters [github.com/disintegration/imaging]: [Smartcrop]: [Exif]: diff --git a/content/en/content-management/menus.md b/content/en/content-management/menus.md index e2a72f124..1f5d1ef71 100644 --- a/content/en/content-management/menus.md +++ b/content/en/content-management/menus.md @@ -48,7 +48,7 @@ To add a page to the "main" menu: {{< code-toggle file=content/about.md fm=true >}} title = 'About' -menu = 'main' +menus = 'main' {{< /code-toggle >}} Access the entry with `site.Menus.main` in your templates. See [menu templates] for details. @@ -57,11 +57,15 @@ To add a page to the "main" and "footer" menus: {{< code-toggle file=content/contact.md fm=true >}} title = 'Contact' -menu = ['main','footer'] +menus = ['main','footer'] {{< /code-toggle >}} Access the entry with `site.Menus.main` and `site.Menus.footer` in your templates. See [menu templates] for details. +{{% note %}} +The configuration key in the examples above is `menus`. The `menu` (singular) configuration key is an alias for `menus`. +{{% /note %}} + ### Properties {#properties-front-matter} Use these properties when defining menu entries in front matter: @@ -96,11 +100,11 @@ This front matter menu entry demonstrates some of the available properties: {{< code-toggle file=content/products/software.md fm=true >}} title = 'Software' -[menu.main] +[[menus.main]] parent = 'Products' weight = 20 pre = '' -[menu.main.params] +[menus.main.params] class = 'center' {{< /code-toggle >}} @@ -111,17 +115,17 @@ Access the entry with `site.Menus.main` in your templates. See [menu templates] To define entries for the "main" menu: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] name = 'Home' pageRef = '/' weight = 10 -[[menu.main]] +[[menus.main]] name = 'Products' pageRef = '/products' weight = 20 -[[menu.main]] +[[menus.main]] name = 'Services' pageRef = '/services' weight = 30 @@ -132,12 +136,12 @@ This creates a menu structure that you can access with `site.Menus.main` in your To define entries for the "footer" menu: {{< code-toggle file=hugo >}} -[[menu.footer]] +[[menus.footer]] name = 'Terms' pageRef = '/terms' weight = 10 -[[menu.footer]] +[[menus.footer]] name = 'Privacy' pageRef = '/privacy' weight = 20 @@ -145,6 +149,10 @@ weight = 20 This creates a menu structure that you can access with `site.Menus.footer` in your templates. See [menu templates] for details. +{{% note %}} +The configuration key in the examples above is `menus`. The `menu` (singular) configuration key is an alias for `menus`. +{{% /note %}} + ### Properties {#properties-site-configuration} {{% note %}} @@ -177,34 +185,34 @@ url This nested menu demonstrates some of the available properties: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] name = 'Products' pageRef = '/products' weight = 10 -[[menu.main]] +[[menus.main]] name = 'Hardware' pageRef = '/products/hardware' parent = 'Products' weight = 1 -[[menu.main]] +[[menus.main]] name = 'Software' pageRef = '/products/software' parent = 'Products' weight = 2 -[[menu.main]] +[[menus.main]] name = 'Services' pageRef = '/services' weight = 20 -[[menu.main]] +[[menus.main]] name = 'Hugo' pre = '' url = 'https://gohugo.io/' weight = 30 -[menu.main.params] +[menus.main.params] rel = 'external' {{< /code-toggle >}} diff --git a/content/en/content-management/multilingual.md b/content/en/content-management/multilingual.md index 07eecbaaf..ea9f71787 100644 --- a/content/en/content-management/multilingual.md +++ b/content/en/content-management/multilingual.md @@ -71,7 +71,7 @@ disabled : (`bool`) If `true`, Hugo will not render content for this language. Default is `false`. languageCode -: (`string`) The language tag as defined by [RFC 5646]. This value may include upper and lower case characters, hyphens or underscores, and does not affect localization or URLs. Hugo uses this value to populate the `language` element in the [built-in RSS template], and the `lang` attribute of the `html` element in the [built-in alias template]. Examples: +: (`string`) The language tag as defined by [RFC 5646]. This value may include upper and lower case characters, hyphens, or underscores, and does not affect localization or URLs. Hugo uses this value to populate the `language` element in the [built-in RSS template], and the `lang` attribute of the `html` element in the [built-in alias template]. Examples: - `en` - `en-GB` @@ -546,12 +546,12 @@ languageCode = 'de-DE' languageName = 'Deutsch' weight = 1 -[[languages.de.menu.main]] +[[languages.de.menus.main]] name = 'Produkte' pageRef = '/products' weight = 10 -[[languages.de.menu.main]] +[[languages.de.menus.main]] name = 'Leistungen' pageRef = '/services' weight = 20 @@ -561,12 +561,12 @@ languageCode = 'en-US' languageName = 'English' weight = 2 -[[languages.en.menu.main]] +[[languages.en.menus.main]] name = 'Products' pageRef = '/products' weight = 10 -[[languages.en.menu.main]] +[[languages.en.menus.main]] name = 'Services' pageRef = '/services' weight = 20 @@ -579,13 +579,12 @@ With a more complex menu structure, create a [configuration directory] and split ```text config/ └── _default/ - ├── menus/ - │ ├── menu.de.toml - │ └── menu.en.toml + ├── menus.de.toml + ├── menus.en.toml └── hugo.toml ``` -{{< code-toggle file=config/_default/menus/menu.de >}} +{{< code-toggle file=config/_default/menus.de >}} [[main]] name = 'Produkte' pageRef = '/products' @@ -596,7 +595,7 @@ pageRef = '/services' weight = 20 {{< /code-toggle >}} -{{< code-toggle file=config/_default/menus/menu.en >}} +{{< code-toggle file=config/_default/menus.en >}} [[main]] name = 'Products' pageRef = '/products' @@ -627,12 +626,12 @@ The `identifier` depends on how you define menu entries: For example, if you define menu entries in site configuration: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] identifier = 'products' name = 'Products' pageRef = '/products' weight = 10 -[[menu.main]] +[[menus.main]] identifier = 'services' name = 'Services' pageRef = '/services' diff --git a/content/en/content-management/summaries.md b/content/en/content-management/summaries.md index 2ff1fec34..22ed3fc81 100644 --- a/content/en/content-management/summaries.md +++ b/content/en/content-management/summaries.md @@ -73,7 +73,7 @@ Cons Because there are multiple ways in which a summary can be specified it is useful to understand the order of selection Hugo follows when deciding on the text to be returned by `.Summary`. It is as follows: -1. If there is a ``> summary divider present in the article the text up to the divider will be provided as per the manual summary split method +1. If there is a `` summary divider present in the article, the text up to the divider will be provided as per the manual summary split method 2. If there is a `summary` variable in the article front matter the value of the variable will be provided as per the front matter summary method 3. The text at the start of the article will be provided as per the automatic summary split method diff --git a/content/en/contribute/documentation.md b/content/en/contribute/documentation.md index 14df5cdee..862df619f 100644 --- a/content/en/contribute/documentation.md +++ b/content/en/contribute/documentation.md @@ -100,7 +100,7 @@ Level 6 markdown headings are styled as `dt` elements. This was implemented to s ## Code examples -Indent code by two spaces. With examples of template code, include a space after opening action delimiters, and include a space before closing action delimeters. +Indent code by two spaces. With examples of template code, include a space after opening action delimiters, and include a space before closing action delimiters. ### Fenced code blocks @@ -269,7 +269,7 @@ Use the "note" shortcode with `{{%/* */%}}` delimiters to call attention to impo Use the [`math.Mod`] function to control... [`math.Mod`]: /functions/math/mod/ -{{%/* /code */%}} +{{%/* /note */%}} ``` Rendered: @@ -278,7 +278,7 @@ Rendered: Use the [`math.Mod`] function to control... [`math.Mod`]: /functions/math/mod/ -{{% /code %}} +{{% /note %}} ## New features @@ -306,13 +306,9 @@ When deprecating a function or method, add this to front matter: {{< code-toggle file=content/something/foo.md fm=true >}} expiryDate: 2024-10-30 -_build: - list: never {{< /code-toggle >}} -Set the `expiryDate` to one year from the date of deprecation, and add a brief front matter comment to explain the settings. - -Users will be able to search for the page, but the page will not appear in any list views, including section menus. +Set the `expiryDate` to one year from the date of deprecation, and add a brief front matter comment to explain the setting. ## GitHub workflow @@ -348,13 +344,13 @@ Closes #1234 Closes #5678" ``` -Step 5 +Step 6 : Push the new branch to your fork of the documentation repository. -Step 6 +Step 7 : Visit the [documentation repository] and create a pull request (PR). -Step 7 +Step 8 : A project maintainer will review your PR and may request changes. You may delete your branch after the maintainer merges your PR. [ATX]: https://spec.commonmark.org/0.30/#atx-headings diff --git a/content/en/functions/collections/Append.md b/content/en/functions/collections/Append.md index 5632dccfb..cb29dc2f2 100644 --- a/content/en/functions/collections/Append.md +++ b/content/en/functions/collections/Append.md @@ -7,7 +7,6 @@ action: aliases: [append] related: - functions/collections/Merge - - functions/collections/Slice returnType: any signatures: - collections.Append ELEMENT [ELEMENT...] COLLECTION @@ -82,7 +81,7 @@ To create a slice of slices, starting with an empty slice: {{ $s = $s | append (slice (slice "a" "b")) }} {{ $s }} → [[a b]] -{{ $s = $s | append (slice "c" "d") }} +{{ $s = $s | append (slice "c" "d") }} {{ $s }} → [[a b] [c d]] ``` diff --git a/content/en/functions/collections/Apply.md b/content/en/functions/collections/Apply.md index abd6fca77..9153e546a 100644 --- a/content/en/functions/collections/Apply.md +++ b/content/en/functions/collections/Apply.md @@ -5,14 +5,9 @@ categories: [] keywords: [] action: aliases: [apply] + related: [] returnType: '[]any' signatures: [collections.Apply COLLECTION FUNCTION PARAM...] -relatedFunctions: - - collections.Delimit - - collections.In - - collections.Reverse - - collections.Seq - - collections.Slice aliases: [/functions/apply] --- diff --git a/content/en/functions/collections/Delimit.md b/content/en/functions/collections/Delimit.md index 6aea467ee..b85059d4b 100644 --- a/content/en/functions/collections/Delimit.md +++ b/content/en/functions/collections/Delimit.md @@ -6,11 +6,6 @@ keywords: [] action: aliases: [delimit] related: - - functions/collections/Apply - - functions/collections/In - - functions/collections/Reverse - - functions/collections/Seq - - functions/collections/Slice - functions/strings/Split returnType: string signatures: ['collections.Delimit COLLECTION DELIMITER [LAST]'] diff --git a/content/en/functions/collections/Dictionary.md b/content/en/functions/collections/Dictionary.md index 2e933aca9..f46b02e75 100644 --- a/content/en/functions/collections/Dictionary.md +++ b/content/en/functions/collections/Dictionary.md @@ -6,10 +6,7 @@ keywords: [] action: aliases: [dict] related: - - functions/collections/Group - - functions/collections/IndexFunction - - functions/collections/IsSet - - functions/collections/Where + - functions/collections/Slice returnType: mapany signatures: ['collections.Dictionary KEY VALUE [VALUE...]'] aliases: [/functions/dict] diff --git a/content/en/functions/collections/First.md b/content/en/functions/collections/First.md index 49a0362f5..cb2397af1 100644 --- a/content/en/functions/collections/First.md +++ b/content/en/functions/collections/First.md @@ -8,6 +8,7 @@ action: related: - functions/collections/After - functions/collections/Last + - methods/pages/Limit returnType: any signatures: [collections.First N COLLECTION] aliases: [/functions/first] diff --git a/content/en/functions/collections/Group.md b/content/en/functions/collections/Group.md index 74aa869df..2f5a333c0 100644 --- a/content/en/functions/collections/Group.md +++ b/content/en/functions/collections/Group.md @@ -5,11 +5,7 @@ categories: [] keywords: [] action: aliases: [group] - related: - - functions/collections/Dictionary - - functions/collections/IndexFunction - - functions/collections/IsSet - - functions/collections/Where + related: [] returnType: any signatures: [collections.Group KEY PAGES] aliases: [/functions/group] diff --git a/content/en/functions/collections/In.md b/content/en/functions/collections/In.md index a3ec83d9b..131c0abcf 100644 --- a/content/en/functions/collections/In.md +++ b/content/en/functions/collections/In.md @@ -6,7 +6,6 @@ keywords: [] action: aliases: [in] related: - - functions/collections/Slice - functions/strings/Contains - functions/strings/ContainsAny - functions/strings/ContainsNonSpace diff --git a/content/en/functions/collections/IndexFunction.md b/content/en/functions/collections/IndexFunction.md index e595d2b41..6482884fd 100644 --- a/content/en/functions/collections/IndexFunction.md +++ b/content/en/functions/collections/IndexFunction.md @@ -5,11 +5,7 @@ categories: [] keywords: [] action: aliases: [index] - related: - - functions/collections/Dictionary - - functions/collections/Group - - functions/collections/IsSet - - functions/collections/Where + related: [] returnType: any signatures: - collections.Index COLLECTION INDEXES diff --git a/content/en/functions/collections/IsSet.md b/content/en/functions/collections/IsSet.md index 76b336ae3..62b81b712 100644 --- a/content/en/functions/collections/IsSet.md +++ b/content/en/functions/collections/IsSet.md @@ -6,10 +6,6 @@ keywords: [] action: aliases: [isset] related: - - functions/collections/Dictionary - - functions/collections/Group - - functions/collections/IndexFunction - - functions/collections/Where - functions/go-template/if - functions/go-template/with returnType: bool diff --git a/content/en/functions/collections/NewScratch.md b/content/en/functions/collections/NewScratch.md index 793b2b4b5..96f85a8d0 100644 --- a/content/en/functions/collections/NewScratch.md +++ b/content/en/functions/collections/NewScratch.md @@ -8,6 +8,7 @@ action: related: - methods/page/scratch - methods/page/store + - methods/shortcode/scratch returnType: maps.Scratch signatures: [collections.NewScratch ] --- @@ -20,16 +21,18 @@ The `collections.NewScratch` function creates a locally scoped [scratch pad] to ## Methods -Set -: Sets the value of a given key. +###### Set + +Sets the value of a given key. ```go-html-template {{ $s := newScratch }} {{ $s.Set "greeting" "Hello" }} ``` -Get -: Gets the value of a given key. +###### Get + +Gets the value of a given key. ```go-html-template {{ $s := newScratch }} @@ -37,10 +40,11 @@ Get {{ $s.Get "greeting" }} → Hello ``` -Add -: Adds a given value to existing value(s) of the given key. +###### Add -: For single values, `Add` accepts values that support Go's `+` operator. If the first `Add` for a key is an array or slice, the following adds will be appended to that list. +Adds a given value to existing value(s) of the given key. + +For single values, `Add` accepts values that support Go's `+` operator. If the first `Add` for a key is an array or slice, the following adds will be appended to that list. ```go-html-template {{ $s := newScratch }} @@ -63,8 +67,9 @@ Add {{ $s.Get "greetings" }} → [Hello Welcome Cheers] ``` -SetInMap -: Takes a `key`, `mapKey` and `value` and adds a map of `mapKey` and `value` to the given `key`. +###### SetInMap + +Takes a `key`, `mapKey` and `value` and adds a map of `mapKey` and `value` to the given `key`. ```go-html-template {{ $s := newScratch }} @@ -73,8 +78,9 @@ SetInMap {{ $s.Get "greetings" }} → map[english:Hello french:Bonjour] ``` -DeleteInMap -: Takes a `key` and `mapKey` and removes the map of `mapKey` from the given `key`. +###### DeleteInMap + +Takes a `key` and `mapKey` and removes the map of `mapKey` from the given `key`. ```go-html-template {{ $s := newScratch }} @@ -84,8 +90,9 @@ DeleteInMap {{ $s.Get "greetings" }} → map[french:Bonjour] ``` -GetSortedMapValues -: Returns an array of values from `key` sorted by `mapKey`. +###### GetSortedMapValues + +Returns an array of values from `key` sorted by `mapKey`. ```go-html-template {{ $s := newScratch }} @@ -94,8 +101,9 @@ GetSortedMapValues {{ $s.GetSortedMapValues "greetings" }} → [Hello Bonjour] ``` -Delete -: Removes the given key. +###### Delete + +Removes the given key. ```go-html-template {{ $s := newScratch }} @@ -103,8 +111,9 @@ Delete {{ $s.Delete "greeting" }} ``` -Values -: Returns the raw backing map. Do not use with `Scratch` or `Store` methods on a `Page` object due to concurrency issues. +###### Values + +Returns the raw backing map. Do not use with `Scratch` or `Store` methods on a `Page` object due to concurrency issues. ```go-html-template {{ $s := newScratch }} diff --git a/content/en/functions/collections/Querify.md b/content/en/functions/collections/Querify.md index e195c417f..ea0434fc5 100644 --- a/content/en/functions/collections/Querify.md +++ b/content/en/functions/collections/Querify.md @@ -5,13 +5,12 @@ categories: [] keywords: [] action: aliases: [querify] + related: + - functions/go-template/urlquery.md returnType: string signatures: - collections.Querify VALUE [VALUE...] - collections.Querify COLLECTION -related: - - collections.Querify - - urlquery aliases: [/functions/querify] --- diff --git a/content/en/functions/collections/Reverse.md b/content/en/functions/collections/Reverse.md index 12c964c76..d0a449763 100644 --- a/content/en/functions/collections/Reverse.md +++ b/content/en/functions/collections/Reverse.md @@ -5,15 +5,12 @@ categories: [] keywords: [] action: aliases: [] + related: + - functions/collections/Sort + - functions/collections/Shuffle + - functions/collections/Uniq returnType: any signatures: [collections.Reverse COLLECTION] -related: - - collections.Apply - - collections.Delimit - - collections.In - - collections.Reverse - - collections.Seq - - collections.Slice aliases: [/functions/collections.reverse] --- diff --git a/content/en/functions/collections/Seq.md b/content/en/functions/collections/Seq.md index e7430e0d0..b572bd7c0 100644 --- a/content/en/functions/collections/Seq.md +++ b/content/en/functions/collections/Seq.md @@ -5,18 +5,12 @@ categories: [] keywords: [] action: aliases: [seq] + related: [] returnType: '[]int' signatures: - collections.Seq LAST - collections.Seq FIRST LAST - collections.Seq FIRST INCREMENT LAST -related: - - collections.Apply - - collections.Delimit - - collections.In - - collections.Reverse - - collections.Seq - - collections.Slice aliases: [/functions/seq] --- @@ -27,7 +21,7 @@ aliases: [/functions/seq] {{ seq -2 2 2 }} → [-2 0 2] ``` -Iterate over a sequence of integers: +A contrived example of iterating over a sequence of integers: ```go-html-template {{ $product := 1 }} @@ -37,10 +31,6 @@ Iterate over a sequence of integers: {{ $product }} → 24 ``` -The example above is contrived. To calculate the product of 2 or more numbers, use the [`math.Product`] function: - -```go-html-template -{{ math.Product (seq 4) }} → 24 -``` - -[`math.Product`]: /functions/math/product +{{% note %}} +The slice created by the `seq` function is limited to 2000 elements. +{{% /note %}} diff --git a/content/en/functions/collections/Shuffle.md b/content/en/functions/collections/Shuffle.md index 18b8cc664..0f28eb4d8 100644 --- a/content/en/functions/collections/Shuffle.md +++ b/content/en/functions/collections/Shuffle.md @@ -5,13 +5,12 @@ categories: [] keywords: [] action: aliases: [shuffle] + related: + - functions/collections/Reverse + - functions/collections/Sort + - functions/collections/Uniq returnType: any signatures: [collections.Shuffle COLLECTION] -related: - - collections.Reverse - - collections.Shuffle - - collections.Sort - - collections.Uniq aliases: [/functions/shuffle] --- diff --git a/content/en/functions/collections/Slice.md b/content/en/functions/collections/Slice.md index e24b394ca..56c068d4b 100644 --- a/content/en/functions/collections/Slice.md +++ b/content/en/functions/collections/Slice.md @@ -5,16 +5,10 @@ categories: [] keywords: [] action: aliases: [slice] + related: + - functions/collections/Dictionary returnType: any signatures: [collections.Slice ITEM...] -related: - - collections.Append - - collections.Apply - - collections.Delimit - - collections.In - - collections.Reverse - - collections.Seq - - collections.Slice aliases: [/functions/slice] --- diff --git a/content/en/functions/collections/Sort.md b/content/en/functions/collections/Sort.md index 6b9ea2c34..2277f883c 100644 --- a/content/en/functions/collections/Sort.md +++ b/content/en/functions/collections/Sort.md @@ -5,13 +5,13 @@ categories: [] keywords: [] action: aliases: [sort] + related: + - functions/collections/Reverse + - functions/collections/Shuffle + - functions/collections/Uniq returnType: any signatures: ['collections.Sort COLLECTION [KEY] [ORDER]'] -related: - - collections.Reverse - - collections.Shuffle - - collections.Sort - - collections.Uniq +toc: true aliases: [/functions/sort] --- @@ -105,6 +105,40 @@ This produces: Victor Marius Jean ``` +### First level key removal + +Hugo removes the first level keys when sorting a map. + +Original map: + +```json +{ + "felix": { + "breed": "malicious", + "type": "cat" + }, + "spot": { + "breed": "boxer", + "type": "dog" + } +} +``` + +After sorting: + +```json +[ + { + "breed": "malicious", + "type": "cat" + }, + { + "breed": "boxer", + "type": "dog" + } +] +``` + ## Sort a page collection {{% note %}} diff --git a/content/en/functions/collections/SymDiff.md b/content/en/functions/collections/SymDiff.md index 828c10ce5..7eba3ef42 100644 --- a/content/en/functions/collections/SymDiff.md +++ b/content/en/functions/collections/SymDiff.md @@ -5,13 +5,13 @@ categories: [] keywords: [] action: aliases: [symdiff] + related: + - functions/collections/Complement + - functions/collections/Intersect + - functions/collections/SymDiff + - functions/collections/Union returnType: any signatures: [COLLECTION | collections.SymDiff COLLECTION] -related: - - collections.Complement - - collections.Intersect - - collections.SymDiff - - collections.Union aliases: [/functions/symdiff] --- diff --git a/content/en/functions/collections/Union.md b/content/en/functions/collections/Union.md index e2eb61313..7fed49a10 100644 --- a/content/en/functions/collections/Union.md +++ b/content/en/functions/collections/Union.md @@ -5,13 +5,13 @@ categories: [] keywords: [] action: aliases: [union] + related: + - functions/collections/Complement + - functions/collections/Intersect + - functions/collections/SymDiff + - functions/collections/Union returnType: any signatures: [collections.Union SET1 SET2] -related: - - collections.Complement - - collections.Intersect - - collections.SymDiff - - collections.Union aliases: [/functions/union] --- diff --git a/content/en/functions/collections/Uniq.md b/content/en/functions/collections/Uniq.md index 8266142ac..02b590c18 100644 --- a/content/en/functions/collections/Uniq.md +++ b/content/en/functions/collections/Uniq.md @@ -5,13 +5,13 @@ categories: [] keywords: [] action: aliases: [uniq] + related: + - functions/collections/Reverse + - functions/collections/Shuffle + - functions/collections/Sort + - functions/collections/Uniq returnType: any signatures: [collections.Uniq COLLECTION] -related: - - collections.Reverse - - collections.Shuffle - - collections.Sort - - collections.Uniq aliases: [/functions/uniq] --- diff --git a/content/en/functions/collections/Where.md b/content/en/functions/collections/Where.md index e053ed3d5..ca900d85e 100644 --- a/content/en/functions/collections/Where.md +++ b/content/en/functions/collections/Where.md @@ -5,16 +5,11 @@ categories: [] keywords: [] action: aliases: [where] + related: [] returnType: any signatures: ['collections.Where COLLECTION KEY [OPERATOR] VALUE'] -related: - - collections.Dictionary - - collections.Group - - collections.Index - - collections.IsSet - - collections.Where -aliases: [/functions/where] toc: true +aliases: [/functions/where] --- The `where` function returns the given collection, removing elements that do not satisfy the comparison condition. The comparison condition is comprised of the `KEY`, `OPERATOR`, and `VALUE` arguments: @@ -37,9 +32,10 @@ Hugo will test for equality if you do not provide an `OPERATOR` argument. For ex The where function takes three or four arguments. The `OPERATOR` argument is optional. COLLECTION -: (`any`) Typically a page collection or a [slice] of [maps]. +: (`any`) A [page collection] or a [slice] of [maps]. [maps]: /getting-started/glossary/#map +[page collection]: /getting-started/glossary/#page-collection [slice]: /getting-started/glossary/#slice KEY @@ -50,7 +46,7 @@ KEY ``` [chain]: /getting-started/glossary/#chain - +Typically a OPERATOR : (`string`) The logical comparison [operator](#operators). @@ -64,7 +60,7 @@ Comparison|Result `false "eq" "false"`|`false` `false "eq" false`|`true` -When one or both of the values to compare is a slice, use the `in`, `not in` or `intersect` operators as described below. +When one or both of the values to compare is a slice, use the `in`, `not in`, or `intersect` operators as described below. ## Operators @@ -123,14 +119,14 @@ Compare the value of the given field to an [`int`] or [`float`]: [`float`]: /getting-started/glossary/#float ```go-html-template -{{ $sectionPages := where site.RegularPages "Section" "eq" "books" }} +{{ $books := where site.RegularPages "Section" "eq" "books" }} -{{ $pages := where $sectionPages "Params.price" "eq" 42 }} -{{ $pages := where $sectionPages "Params.price" "ne" 42.67 }} -{{ $pages := where $sectionPages "Params.price" "ge" 42 }} -{{ $pages := where $sectionPages "Params.price" "gt" 42.67 }} -{{ $pages := where $sectionPages "Params.price" "le" 42 }} -{{ $pages := where $sectionPages "Params.price" "lt" 42.67 }} +{{ $pages := where $books "Params.price" "eq" 42 }} +{{ $pages := where $books "Params.price" "ne" 42.67 }} +{{ $pages := where $books "Params.price" "ge" 42 }} +{{ $pages := where $books "Params.price" "gt" 42.67 }} +{{ $pages := where $books "Params.price" "le" 42 }} +{{ $pages := where $books "Params.price" "lt" 42.67 }} ``` ## Boolean comparison @@ -140,12 +136,12 @@ Compare the value of the given field to a [`bool`]: [`bool`]: /getting-started/glossary/#bool ```go-html-template -{{ $sectionPages := where site.RegularPages "Section" "eq" "books" }} +{{ $books := where site.RegularPages "Section" "eq" "books" }} -{{ $pages := where $sectionPages "Params.fiction" "eq" true }} -{{ $pages := where $sectionPages "Params.fiction" "eq" false }} -{{ $pages := where $sectionPages "Params.fiction" "ne" true }} -{{ $pages := where $sectionPages "Params.fiction" "ne" false }} +{{ $pages := where $books "Params.fiction" "eq" true }} +{{ $pages := where $books "Params.fiction" "eq" false }} +{{ $pages := where $books "Params.fiction" "ne" true }} +{{ $pages := where $books "Params.fiction" "ne" false }} ``` ## Member comparison @@ -158,19 +154,19 @@ Compare a [`scalar`] to a [`slice`]. For example, to return a collection of pages where the `color` page parameter is either "red" or "yellow": ```go-html-template -{{ $sectionPages := where site.RegularPages "Section" "eq" "fruit" }} +{{ $fruit := where site.RegularPages "Section" "eq" "fruit" }} {{ $colors := slice "red" "yellow" }} -{{ $pages := where $sectionPages "Params.color" "in" $colors }} +{{ $pages := where $fruit "Params.color" "in" $colors }} ``` To return a collection of pages where the "color" page parameter is neither "red" nor "yellow": ```go-html-template -{{ $sectionPages := where site.RegularPages "Section" "eq" "fruit" }} +{{ $fruit := where site.RegularPages "Section" "eq" "fruit" }} {{ $colors := slice "red" "yellow" }} -{{ $pages := where $sectionPages "Params.color" "not in" $colors }} +{{ $pages := where $fruit "Params.color" "not in" $colors }} ``` ## Intersection comparison @@ -180,10 +176,10 @@ Compare a [`slice`] to a [`slice`], returning collection elements with common va For example, to return a collection of pages where any of the terms in the "genres" taxonomy are "suspense" or "romance": ```go-html-template -{{ $sectionPages := where site.RegularPages "Section" "eq" "books" }} +{{ $books := where site.RegularPages "Section" "eq" "books" }} {{ $genres := slice "suspense" "romance" }} -{{ $pages := where $sectionPages "Params.genres" "intersect" $genres }} +{{ $pages := where $books "Params.genres" "intersect" $genres }} ``` ## Regular expression comparison diff --git a/content/en/functions/crypto/FNV32a.md b/content/en/functions/crypto/FNV32a.md index 5c091ebee..eda303e62 100644 --- a/content/en/functions/crypto/FNV32a.md +++ b/content/en/functions/crypto/FNV32a.md @@ -1,6 +1,6 @@ --- title: crypto.FNV32a -description: Returns the FNV (Fowler–Noll–Vo) 32 bit hash of a given string. +description: Returns the FNV (Fowler–Noll–Vo) 32-bit hash of a given string. categories: [] keywords: [] action: @@ -15,7 +15,7 @@ action: aliases: [/functions/crypto.fnv32a] --- -This function calculates the 32 bit [FNV1a hash](https://en.wikipedia.org/wiki/Fowler%E2%80%93Noll%E2%80%93Vo_hash_function#FNV-1a_hash) of a given string according to the [specification](https://datatracker.ietf.org/doc/html/draft-eastlake-fnv-12): +This function calculates the 32-bit [FNV1a hash](https://en.wikipedia.org/wiki/Fowler%E2%80%93Noll%E2%80%93Vo_hash_function#FNV-1a_hash) of a given string according to the [specification](https://datatracker.ietf.org/doc/html/draft-eastlake-fnv-12): ```go-html-template {{ crypto.FNV32a "Hello world" }} → 1498229191 diff --git a/content/en/functions/data/GetJSON.md b/content/en/functions/data/GetJSON.md index 96812e7c0..4db3c8988 100644 --- a/content/en/functions/data/GetJSON.md +++ b/content/en/functions/data/GetJSON.md @@ -89,8 +89,7 @@ my-project/ {{ $data := "" }} {{ $p := "data/books.json" }} {{ with resources.Get $p }} - {{ $opts := dict "delimiter" "," }} - {{ $data = . | transform.Unmarshal $opts }} + {{ $data = . | transform.Unmarshal }} {{ else }} {{ errorf "Unable to get resource %q" $p }} {{ end }} @@ -113,8 +112,7 @@ my-project/ {{ $data := "" }} {{ $p := "books.json" }} {{ with .Resources.Get $p }} - {{ $opts := dict "delimiter" "," }} - {{ $data = . | transform.Unmarshal $opts }} + {{ $data = . | transform.Unmarshal }} {{ else }} {{ errorf "Unable to get resource %q" $p }} {{ end }} @@ -131,8 +129,7 @@ Consider using the [`resources.GetRemote`] function with [`transform.Unmarshal`] {{ with .Err }} {{ errorf "%s" . }} {{ else }} - {{ $opts := dict "delimiter" "," }} - {{ $data = . | transform.Unmarshal $opts }} + {{ $data = . | transform.Unmarshal }} {{ end }} {{ else }} {{ errorf "Unable to get remote resource %q" $u }} diff --git a/content/en/functions/fmt/Warnf.md b/content/en/functions/fmt/Warnf.md index b07cf3cc3..0a90251d3 100644 --- a/content/en/functions/fmt/Warnf.md +++ b/content/en/functions/fmt/Warnf.md @@ -20,3 +20,14 @@ The `warnf` function evaluates the format string, then prints the result to the ```go-html-template {{ warnf "The %q shortcode was unable to find %s. See %s" .Name $file .Position }} ``` + +To prevent suppression of duplicate messages when using `warnf` for debugging, make each message unique with the [`math.Counter`] function. For example: + + +```go-html-template +{{ range site.RegularPages }} + {{ .Section | warnf "%#[2]v [%[1]d]" math.Counter }} +{{ end }} +``` + +[`math.Counter`]: /functions/math/counter diff --git a/content/en/functions/global/page.md b/content/en/functions/global/page.md index e17fb0767..6c96b747e 100644 --- a/content/en/functions/global/page.md +++ b/content/en/functions/global/page.md @@ -86,7 +86,7 @@ Do not use the global `page` function in: - Partials called by shortcodes - Partials cached by the [`partialCached`] function -Hugo caches rendered shortcodes. If you use the global `page` function within a shortcode, and the page content is rendered in two or more templates, the cached shortcodes may be incorrect. +Hugo caches rendered shortcodes. If you use the global `page` function within a shortcode, and the page content is rendered in two or more templates, the cached shortcode may be incorrect. Consider this section template: diff --git a/content/en/functions/go-template/range.md b/content/en/functions/go-template/range.md index e8642e50b..e2f401371 100644 --- a/content/en/functions/go-template/range.md +++ b/content/en/functions/go-template/range.md @@ -20,7 +20,7 @@ toc: true ```go-html-template {{ $s := slice "foo" "bar" "baz" }} -{{ range $var }} +{{ range $s }} {{ . }} → foo bar baz {{ end }} ``` diff --git a/content/en/functions/go-template/with.md b/content/en/functions/go-template/with.md index 197181953..0f3255b1a 100644 --- a/content/en/functions/go-template/with.md +++ b/content/en/functions/go-template/with.md @@ -36,7 +36,7 @@ Use with the [`else`] statement: {{ end }} ``` -Intialize a variable, scoped to the current block: +Initialize a variable, scoped to the current block: ```go-html-template {{ with $var := 42 }} diff --git a/content/en/functions/images/AutoOrient.md b/content/en/functions/images/AutoOrient.md new file mode 100644 index 000000000..8f27a95d8 --- /dev/null +++ b/content/en/functions/images/AutoOrient.md @@ -0,0 +1,52 @@ +--- +title: images.AutoOrient +description: Returns an image filter that rotates and flips an image as needed per its EXIF orientation tag. +categories: [] +keywords: [] +action: + aliases: [] + related: + - functions/images/Filter + - methods/resource/Filter + returnType: images.filter + signatures: [images.AutoOrient] +toc: true +--- + +{{< new-in 0.121.2 >}} + +## Usage + +Create the filter: + +```go-html-template +{{ $filter := images.AutoOrient }} +``` + +{{% include "functions/images/_common/apply-image-filter.md" %}} + +{{% note %}} +When using with other filters, specify `images.AutoOrient` first. +{{% /note %}} + +```go-html-template +{{ $filters := slice + images.AutoOrient + (images.Process "resize 200x") +}} +{{ with resources.Get "images/original.jpg" }} + {{ with images.Filter $filters . }} + + {{ end }} +{{ end }} +``` + +## Example + +{{< img + src="images/examples/landscape-exif-orientation-5.jpg" + alt="Zion National Park" + filter="AutoOrient" + filterArgs="" + example=true +>}} diff --git a/content/en/functions/images/Text.md b/content/en/functions/images/Text.md index 0c1e74bce..8c6670d42 100644 --- a/content/en/functions/images/Text.md +++ b/content/en/functions/images/Text.md @@ -21,7 +21,9 @@ color : (`string`) The font color, either a 3-digit or 6-digit hexadecimal color code. Default is `#ffffff` (white). font -: (`resource.Resource`) The font can be a [global resource], a [page resource], or a [remote resource]. Default is the "Go Regular" TrueType font. +: (`resource.Resource`) The font can be a [global resource], a [page resource], or a [remote resource]. Default is [Go Regular], a proportional sans-serif TrueType font. + +[Go Regular]: https://go.dev/blog/go-fonts#sans-serif linespacing : (`int`) The number of pixels between each line. For a line height of 1.4, set the `linespacing` to 0.4 multiplied by the `size`. Default is `2`. @@ -45,7 +47,7 @@ Capture the font as a resource: ```go-html-template {{ $font := "" }} -{{ $path := "https://github.com/google/fonts/raw/main/apache/roboto/static/Roboto-Regular.ttf" }} +{{ $path := "https://github.com/google/fonts/raw/main/ofl/lato/Lato-Regular.ttf" }} {{ with resources.GetRemote $path }} {{ with .Err }} {{ errorf "%s" . }} diff --git a/content/en/functions/inflect/Humanize.md b/content/en/functions/inflect/Humanize.md index 41d61a4e5..71b4a5fd2 100644 --- a/content/en/functions/inflect/Humanize.md +++ b/content/en/functions/inflect/Humanize.md @@ -18,7 +18,7 @@ aliases: [/functions/humanize] {{ humanize "myCamelPost" }} → My camel post ``` -If the input is either an int64 value or the string representation of an integer, humanize returns the number with the proper ordinal appended. +If the input is an integer or a string representation of an integer, humanize returns the number with the proper ordinal appended. ```go-html-template {{ humanize "52" }} → 52nd diff --git a/content/en/functions/lang/Translate.md b/content/en/functions/lang/Translate.md index 630098a96..3366d7751 100644 --- a/content/en/functions/lang/Translate.md +++ b/content/en/functions/lang/Translate.md @@ -11,6 +11,23 @@ action: aliases: [/functions/i18n] --- +The `lang.Translate` function returns the value associated with given key as defined in the translation table for the current language. + +If the key is not found in the translation table for the current language, the `lang.Translate` function falls back to the translation table for the [`defaultContentLanguage`]. + +If the key is not found in the translation table for the `defaultContentLanguage`, the `lang.Translate` function returns an empty string. + +[`defaultContentLanguage`]: /getting-started/configuration/#defaultcontentlanguage + +{{% note %}} +To list missing and fallback translations, use the `--printI18nWarnings` flag when building your site. + +To render placeholders for missing and fallback translations, set +[`enableMissingTranslationPlaceholders`] to `true` in your site configuration. + +[`enableMissingTranslationPlaceholders`]: /getting-started/configuration/#enablemissingtranslationplaceholders +{{% /note %}} + Let's say your multilingual site supports two languages, English and Polish. Create a translation table for each language in the `i18n` directory. ```text diff --git a/content/en/functions/math/Rand.md b/content/en/functions/math/Rand.md new file mode 100644 index 000000000..4f71cfcdf --- /dev/null +++ b/content/en/functions/math/Rand.md @@ -0,0 +1,46 @@ +--- +title: math.Rand +description: Returns a pseudo-random number in the half-open interval [0.0, 1.0). +categories: [] +keywords: [] +action: + aliases: [] + related: [] + returnType: float64 + signatures: [math.Rand] +--- + +{{< new-in 0.121.2 >}} + +The `math.Rand` function returns a pseudo-random number in the [half-open interval] [0.0, 1.0). + +```go-html-template +{{ math.Rand }} → 0.6312770459590062 +``` + +To generate a random integer in the [closed interval] [0, 5]: + +```go-html-template +{{ math.Rand | mul 6 | math.Floor }} +``` + +To generate a random integer in the closed interval [1, 6]: + +```go-html-template +{{ math.Rand | mul 6 | math.Ceil }} +``` + +To generate a random float, with one digit after the decimal point, in the closed interval [0, 4.9]: + +```go-html-template +{{ div (math.Rand | mul 50 | math.Floor) 10 }} +``` + +To generate a random float, with one digit after the decimal point, in the closed interval [0.1, 5.0]: + +```go-html-template +{{ div (math.Rand | mul 50 | math.Ceil) 10 }} +``` + +[closed interval]: /getting-started/glossary/#interval +[half-open interval]: /getting-started/glossary/#interval diff --git a/content/en/functions/math/Sub.md b/content/en/functions/math/Sub.md index 2865ac191..a89d0e69d 100644 --- a/content/en/functions/math/Sub.md +++ b/content/en/functions/math/Sub.md @@ -2,6 +2,7 @@ title: math.Sub description: Subtracts one or more numbers from the first number. categories: [] +keywords: [] action: aliases: [sub] related: diff --git a/content/en/functions/openapi3/Unmarshal.md b/content/en/functions/openapi3/Unmarshal.md index 50c793685..433337aef 100644 --- a/content/en/functions/openapi3/Unmarshal.md +++ b/content/en/functions/openapi3/Unmarshal.md @@ -17,7 +17,7 @@ Use the `openapi3.Unmarshal` function with [global], [page], or [remote] resourc [remote]: /getting-started/glossary/#remote-resource [OpenAPI]: https://www.openapis.org/ -For example, to work with a remote [OpenAPI] defintion: +For example, to work with a remote [OpenAPI] definition: ```go-html-template {{ $url := "https://raw.githubusercontent.com/OAI/OpenAPI-Specification/main/examples/v3.0/petstore.json" }} diff --git a/content/en/functions/partials/Include.md b/content/en/functions/partials/Include.md index 859f6665b..e08b32fd1 100644 --- a/content/en/functions/partials/Include.md +++ b/content/en/functions/partials/Include.md @@ -68,7 +68,7 @@ Then, within the partial template: To return a value from a partial template, it must contain only one `return` statement, placed at the end of the template: ```go-html-template -{{ $result := false }} +{{ $result := "" }} {{ if math.ModBool . 2 }} {{ $result = "even" }} {{ else }} diff --git a/content/en/functions/partials/IncludeCached.md b/content/en/functions/partials/IncludeCached.md index db275fa9e..66ef4a6ac 100644 --- a/content/en/functions/partials/IncludeCached.md +++ b/content/en/functions/partials/IncludeCached.md @@ -51,7 +51,7 @@ The variant arguments are not available to the underlying partial template; they To return a value from a partial template, it must contain only one `return` statement, placed at the end of the template: ```go-html-template -{{ $result := false }} +{{ $result := "" }} {{ if math.ModBool . 2 }} {{ $result = "even" }} {{ else }} diff --git a/content/en/functions/resources/Concat.md b/content/en/functions/resources/Concat.md index 3bdf975bf..809ee83d0 100644 --- a/content/en/functions/resources/Concat.md +++ b/content/en/functions/resources/Concat.md @@ -1,6 +1,6 @@ --- title: resources.Concat -description: Concatenates a slice of resources. +description: Returns a concatenated slice of resources. categories: [] keywords: [] action: @@ -10,12 +10,17 @@ action: signatures: ['resources.Concat TARGETPATH [RESOURCE...]'] --- +The `resources.Concat` function returns a concatenated slice of resources, caching the result using the target path as its cache key. Each resource must have the same [media type]. + +Hugo publishes the resource to the target path when you call its [`Publish`], [`Permalink`], or [`RelPermalink`] methods. + +[media type]: https://en.wikipedia.org/wiki/Media_type +[`publish`]: /methods/resource/publish +[`permalink`]: /methods/resource/permalink +[`relpermalink`]: /methods/resource/relpermalink + ```go-html-template {{ $plugins := resources.Get "js/plugins.js" }} {{ $global := resources.Get "js/global.js" }} {{ $js := slice $plugins $global | resources.Concat "js/bundle.js" }} ``` - -Asset files of the same [media type] can be bundled into one resource using the `resources.Concat` function which takes two arguments, the target path for the created resource bundle and a slice of resource objects to be concatenated. - -[media type]: https://en.wikipedia.org/wiki/Media_type diff --git a/content/en/functions/resources/ExecuteAsTemplate.md b/content/en/functions/resources/ExecuteAsTemplate.md index d17f0580c..5f7e58413 100644 --- a/content/en/functions/resources/ExecuteAsTemplate.md +++ b/content/en/functions/resources/ExecuteAsTemplate.md @@ -1,6 +1,6 @@ --- title: resources.ExecuteAsTemplate -description: Creates a resource from a Go template, parsed and executed with the given context. +description: Returns a resource created from a Go template, parsed and executed with the given context. categories: [] keywords: [] action: @@ -11,7 +11,13 @@ action: signatures: [resources.ExecuteAsTemplate TARGETPATH CONTEXT RESOURCE] --- -Hugo publishes the resource to the target path when you call its`.Publish`, `.Permalink`, or `.RelPermalink` method. The resource is cached, using the target path as the cache key. +The `resources.ExecuteAsTemplate` function returns a resource created from a Go template, parsed and executed with the given context, caching the result using the target path as its cache key. + +Hugo publishes the resource to the target path when you call its [`Publish`], [`Permalink`], or [`RelPermalink`] methods. + +[`publish`]: /methods/resource/publish +[`permalink`]: /methods/resource/permalink +[`relpermalink`]: /methods/resource/relpermalink Let's say you have a CSS file that you wish to populate with values from your site configuration: diff --git a/content/en/functions/resources/FromString.md b/content/en/functions/resources/FromString.md index 6c22b5310..75f48ad9c 100644 --- a/content/en/functions/resources/FromString.md +++ b/content/en/functions/resources/FromString.md @@ -1,6 +1,6 @@ --- title: resources.FromString -description: Creates a resource from a string. +description: Returns a resource created from a string. categories: [] keywords: [] action: @@ -11,7 +11,13 @@ action: signatures: [resources.FromString TARGETPATH STRING] --- -Hugo publishes the resource to the target path when you call its`.Publish`, `.Permalink`, or `.RelPermalink` method. The resource is cached, using the target path as the cache key. +The `resources.FromString` function returns a resource created from a string, caching the result using the target path as its cache key. + +Hugo publishes the resource to the target path when you call its [`Publish`], [`Permalink`], or [`RelPermalink`] methods. + +[`publish`]: /methods/resource/publish +[`permalink`]: /methods/resource/permalink +[`relpermalink`]: /methods/resource/relpermalink Let's say you need to publish a file named "site.json" in the root of your public directory, containing the build date, the Hugo version used to build the site, and the date that the content was last modified. For example: diff --git a/content/en/functions/resources/Minify.md b/content/en/functions/resources/Minify.md index 44f5f990b..9749df20a 100644 --- a/content/en/functions/resources/Minify.md +++ b/content/en/functions/resources/Minify.md @@ -20,4 +20,4 @@ action: {{ $style := $css | minify }} ``` -Any CSS, JS, JSON, HTML, SVG or XML resource can be minified using resources.Minify which takes for argument the resource object. +Any CSS, JS, JSON, HTML, SVG, or XML resource can be minified using resources.Minify which takes for argument the resource object. diff --git a/content/en/functions/resources/ToCSS.md b/content/en/functions/resources/ToCSS.md index 872bf996b..d226f2688 100644 --- a/content/en/functions/resources/ToCSS.md +++ b/content/en/functions/resources/ToCSS.md @@ -139,8 +139,8 @@ To install Dart Sass for your builds on GitLab Pages, the `.gitlab-ci.yml` file ```yaml variables: - HUGO_VERSION: 0.115.1 - DART_SASS_VERSION: 1.63.6 + HUGO_VERSION: 0.121.0 + DART_SASS_VERSION: 1.69.5 GIT_DEPTH: 0 GIT_STRATEGY: clone GIT_SUBMODULE_STRATEGY: recursive @@ -173,8 +173,8 @@ To install Dart Sass for your builds on Netlify, the `netlify.toml` file should ```toml [build.environment] -HUGO_VERSION = "0.115.1" -DART_SASS_VERSION = "1.63.6" +HUGO_VERSION = "0.121.0" +DART_SASS_VERSION = "1.69.5" TZ = "America/Los_Angeles" [build] diff --git a/content/en/functions/safe/HTMLAttr.md b/content/en/functions/safe/HTMLAttr.md index 6e1fd2af7..198fc8ff3 100644 --- a/content/en/functions/safe/HTMLAttr.md +++ b/content/en/functions/safe/HTMLAttr.md @@ -19,7 +19,7 @@ aliases: [/functions/safehtmlattr] Given a site configuration that contains this menu entry: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] name = "IRC" url = "irc://irc.freenode.net/#golang" {{< /code-toggle >}} diff --git a/content/en/functions/safe/URL.md b/content/en/functions/safe/URL.md index 2ae67bd7f..2da6895e5 100644 --- a/content/en/functions/safe/URL.md +++ b/content/en/functions/safe/URL.md @@ -23,7 +23,7 @@ Without `safeURL`, only the URI schemes `http:`, `https:` and `mailto:` are cons The following examples use a [site `hugo.toml`][configuration] with the following [menu entry][menus]: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] name = "IRC: #golang at freenode" url = "irc://irc.freenode.net/#golang" {{< /code-toggle >}} diff --git a/content/en/functions/strings/FindRESubmatch.md b/content/en/functions/strings/FindRESubmatch.md index 029cb323e..302d1d9b4 100644 --- a/content/en/functions/strings/FindRESubmatch.md +++ b/content/en/functions/strings/FindRESubmatch.md @@ -9,7 +9,7 @@ action: - functions/strings/FindRE - functions/strings/Replace - functions/strings/ReplaceRE - returnType: '[]string' + returnType: '[][]string' signatures: ['strings.FindRESubmatch PATTERN INPUT [LIMIT]'] aliases: [/functions/findresubmatch] --- diff --git a/content/en/functions/strings/FindRe.md b/content/en/functions/strings/FindRe.md index d26bae4a3..861f38a12 100644 --- a/content/en/functions/strings/FindRe.md +++ b/content/en/functions/strings/FindRe.md @@ -9,7 +9,7 @@ action: - functions/strings/FindRESubmatch - functions/strings/Replace - functions/strings/ReplaceRE - returnType: string + returnType: '[]string' signatures: ['strings.FindRE PATTERN INPUT [LIMIT]'] aliases: [/functions/findre] --- diff --git a/content/en/functions/strings/HasSuffix.md b/content/en/functions/strings/HasSuffix.md index e7f253ce9..8fb12c527 100644 --- a/content/en/functions/strings/HasSuffix.md +++ b/content/en/functions/strings/HasSuffix.md @@ -1,6 +1,6 @@ --- title: strings.HasSuffix -description: Reports whether the given string begins with the given suffix. +description: Reports whether the given string ends with the given suffix. categories: [] keywords: [] action: diff --git a/content/en/functions/transform/XMLEscape.md b/content/en/functions/transform/XMLEscape.md new file mode 100644 index 000000000..d0aafc4bd --- /dev/null +++ b/content/en/functions/transform/XMLEscape.md @@ -0,0 +1,40 @@ +--- +title: transform.XMLEscape +description: Returns the given string, removing disallowed characters then escaping the result to its XML equivalent. +categories: [] +keywords: [] +action: + aliases: [] + related: [] + returnType: string + signatures: [transform.XMLEscape INPUT] +--- + +{{< new-in 0.121.0 >}} + +The `transform.XMLEscape` function removes [disallowed characters] as defined in the XML specification, then escapes the result by replacing the following characters with [HTML entities]: + +- `"` → `"` +- `'` → `'` +- `&` → `&` +- `<` → `<` +- `>` → `>` +- `\t` → ` ` +- `\n` → ` ` +- `\r` → ` ` + +For example: + +```go-html-template +{{ transform.XMLEscape "

abc

" }} → <p>abc</p> +``` + +When using `transform.XMLEscape` in a template rendered by Go's [html/template] package, declare the string to be safe HTML to avoid double escaping. For example, in an RSS template: + +{{< code file="layouts/_default/rss.xml" >}} +{{ .Summary | transform.XMLEscape | safeHTML }} +{{< /code >}} + +[disallowed characters]: https://www.w3.org/TR/xml/#charsets +[html entities]: https://developer.mozilla.org/en-us/docs/glossary/entity +[html/template]: https://pkg.go.dev/html/template diff --git a/content/en/getting-started/configuration.md b/content/en/getting-started/configuration.md index 2ab5450f3..a2819c7fd 100644 --- a/content/en/getting-started/configuration.md +++ b/content/en/getting-started/configuration.md @@ -15,61 +15,117 @@ aliases: [/overview/source-directory/,/overview/configuration/] ## Configuration file -Hugo uses the `hugo.toml`, `hugo.yaml`, or `hugo.json` (if found in the -site root) as the default site configuration file. +Create a site configuration file in the root of your project directory, naming it `hugo.toml`, `hugo.yaml`, or `hugo.json`, with that order of precedence. -The user can choose to override that default with one or more site configuration files using the command-line `--config` switch. - -Examples: - -```txt -hugo --config debugconfig.toml -hugo --config a.toml,b.toml,c.toml +```text +my-project/ +└── hugo.toml ``` {{% note %}} -Multiple site configuration files can be specified as a comma-separated string to the `--config` switch. +With v0.109.0 and earlier the basename of the site configuration file was `config` instead of `hugo`. You can use either, but should transition to the new naming convention when practical. {{% /note %}} -## hugo.toml vs config.toml +A simple example: -In Hugo 0.110.0 we changed the default configuration base file name to `hugo`, e.g. `hugo.toml`. We will still look for `config.toml` etc., but we recommend you eventually rename it (but you need to wait if you want to support older Hugo versions). The main reason we're doing this is to make it easier for code editors and build tools to identify this as a Hugo configuration file and project. +{{< code-toggle file=hugo >}} +baseURL = 'https://example.org/' +languageCode = 'en-us' +title = 'ABC Widgets, Inc.' +[params] +subtitle = 'The Best Widgets on Earth' +[params.contact] +email = 'info@example.org' +phone = '+1 202-555-1212' +{{< /code-toggle >}} -{{< new-in 0.110.0 >}} +To use a different configuration file when building your site, use the `--config` flag: + +```sh +hugo --config other.toml +``` + +Combine two or more configuration files, with left-to-right precedence: + +```sh +hugo --config a.toml,b.yaml,c.json +``` + +{{% note %}} +See the specifications for each file format: [TOML], [YAML], and [JSON]. + +[TOML]: https://toml.io/en/latest +[YAML]: https://yaml.org/spec/ +[JSON]: https://datatracker.ietf.org/doc/html/rfc7159 +{{% /note %}} ## Configuration directory -In addition to using a single site configuration file, one can use the `configDir` directory (default to `config/`) to maintain easier organization and environment specific settings. +Instead of a single site configuration file, split your configuration by [environment], root configuration key, and language. For example: -- Each file represents a configuration root object, such as `params.toml` for `[Params]`, `menu(s).toml` for `[Menu]`, `languages.toml` for `[Languages]` etc... -- Each file's content must be top-level, for example: +[environment]: /getting-started/glossary/#environment + +```text +my-project/ +└── config/ + ├── _default/ + │ ├── hugo.toml + │ ├── menus.en.toml + │ ├── menus.de.toml + │ └── params.toml + ├── production/ + │ ├── hugo.toml + │ └── params.toml + └── staging/ + ├── hugo.toml + └── params.toml +``` + +The root configuration keys are `build`, `caches`, `cascade`, `deployment`, `frontmatter`, `imaging`, `languages`, `markup`, `mediatypes`, `menus`, `minify`, `module`, `outputformats`, `outputs`, `params`, `permalinks`, `privacy`, `related`, `security`, `server`, `services`, `sitemap`, and `taxonomies`. + +### Omit the root key + +When splitting the configuration by root key, omit the root key in the given file. For example, these are equivalent: {{< code-toggle file=hugo >}} -[Params] - foo = "bar" +[params] +foo = 'bar' {{< /code-toggle >}} {{< code-toggle file=params >}} -foo = "bar" +foo = 'bar' {{< /code-toggle >}} -- Each directory holds a group of files containing settings unique to an environment. -- Files can be localized to become language specific. +### Recursive parsing -```txt -├── config -│ ├── _default -│ │ ├── hugo.toml -│ │ ├── languages.toml -│ │ ├── menus.en.toml -│ │ ├── menus.zh.toml -│ │ └── params.toml -│ ├── production -│ │ ├── hugo.toml -│ │ └── params.toml -│ └── staging -│ ├── hugo.toml -│ └── params.toml +Hugo parses the `config` directory recursively, allowing you to organize the files into subdirectories. For example: + +```text +my-project/ +└── config/ + └── _default/ + ├── navigation/ + │ ├── menus.de.toml + │ └── menus.en.toml + └── hugo.toml +``` + +### Example + +```text +my-project/ +└── config/ + ├── _default/ + │ ├── hugo.toml + │ ├── menus.en.toml + │ ├── menus.de.toml + │ └── params.toml + ├── production/ + │ ├── hugo.toml + │ └── params.toml + └── staging/ + ├── hugo.toml + └── params.toml ``` Considering the structure above, when running `hugo --environment staging`, Hugo will use every setting from `config/_default` and merge `staging`'s on top of those. @@ -144,356 +200,272 @@ Note that you don't need to be so verbose as in the default setup below; a `_mer ## All configuration settings -The following is the full list of Hugo-defined variables. Users may choose to override those values in their site configuration file(s). +###### archetypeDir -### archetypeDir +(`string`) The directory where Hugo finds archetype files (content templates). Default is `archetypes`. {{% module-mounts-note %}} -**Default value:** "archetypes" +###### assetDir -The directory where Hugo finds archetype files (content templates). {{% module-mounts-note %}} +(`string`) The directory where Hugo finds asset files used in [Hugo Pipes](/hugo-pipes/). Default is `assets`. {{% module-mounts-note %}} -### assetDir +###### baseURL -**Default value:** "assets" +(`string`) The absolute URL (protocol, host, path, and trailing slash) of your published site (e.g., `https://www.example.org/docs/`). -The directory where Hugo finds asset files used in [Hugo Pipes](/hugo-pipes/). {{% module-mounts-note %}} +###### build -### baseURL +See [Configure Build](#configure-build). -The absolute URL (protocol, host, path, and trailing slash) of your published site (e.g., `https://www.example.org/docs/`). +###### buildDrafts -### build +(`bool`) Include drafts when building. Default is `false`. -See [Configure Build](#configure-build) +###### buildExpired -### buildDrafts (false) +(`bool`) Include content already expired. Default is `false`. -**Default value:** false +###### buildFuture -Include drafts when building. +(`bool`) Include content with publishdate in the future. Default is `false`. -### buildExpired +###### caches -**Default value:** false +See [Configure File Caches](#configure-file-caches). -Include content already expired. - -### buildFuture - -**Default value:** false - -Include content with publishdate in the future. - -### caches - -See [Configure File Caches](#configure-file-caches) - -### cascade +###### cascade Pass down down default configuration values (front matter) to pages in the content tree. The options in site config is the same as in page front matter, see [Front Matter Cascade](/content-management/front-matter#front-matter-cascade). {{% note %}} For a website in a single language, define the `[[cascade]]` in [Front Matter](/content-management/front-matter#front-matter-cascade). For a multilingual website, define the `[[cascade]]` in [Site Config](../../getting-started/configuration/#cascade). -To remain consistent and prevent unexpected behaviour, do not mix these strategies. +To remain consistent and prevent unexpected behavior, do not mix these strategies. {{% /note %}} -### canonifyURLs +###### canonifyURLs -**Default value:** false +(`bool`) Enable to turn relative URLs into absolute. Default is `false`. See [details](/content-management/urls/#canonical-urls). -Enable to turn relative URLs into absolute. See [details](/content-management/urls/#canonical-urls). +###### cleanDestinationDir -### cleanDestinationDir +(`bool`) When building, removes files from destination not found in static directories. Default is `false`. -**Default value:** false +###### contentDir -When building, removes files from destination not found in static directories. +(`string`) The directory from where Hugo reads content files. Default is `content`. {{% module-mounts-note %}} -### contentDir +###### copyright -**Default value:** "content" +(`string`) Copyright notice for your site, typically displayed in the footer. -The directory from where Hugo reads content files. {{% module-mounts-note %}} +###### dataDir -### copyright +(`string`) The directory from where Hugo reads data files. Default is `data`. {{% module-mounts-note %}} -**Default value:** "" +###### defaultContentLanguage -Copyright notice for your site, typically displayed in the footer. +(`string`) Content without language indicator will default to this language. Default is `en`. -### dataDir +###### defaultContentLanguageInSubdir -**Default value:** "data" +(`bool`) Render the default content language in subdir, e.g. `content/en/`. The site root `/` will then redirect to `/en/`. Default is `false`. -The directory from where Hugo reads data files. {{% module-mounts-note %}} +###### disableAliases -### defaultContentLanguage +(`bool`) Will disable generation of alias redirects. Note that even if `disableAliases` is set, the aliases themselves are preserved on the page. The motivation with this is to be able to generate 301 redirects in an `.htaccess`, a Netlify `_redirects` file or similar using a custom output format. Default is `false`. -**Default value:** "en" +###### disableHugoGeneratorInject -Content without language indicator will default to this language. +(`bool`) Hugo will, by default, inject a generator meta tag in the HTML head on the _home page only_. You can turn it off, but we would really appreciate if you don't, as this is a good way to watch Hugo's popularity on the rise. Default is `false`. -### defaultContentLanguageInSubdir +###### disableKinds -**Default value:** false +(`string slice`) Disable rendering of the specified page [kinds], any of `404`, `home`, `page`, `robotstxt`, `rss`, `section`, `sitemap`, `taxonomy`, or `term`. -Render the default content language in subdir, e.g. `content/en/`. The site root `/` will then redirect to `/en/`. +[kinds]: /getting-started/glossary/#page-kind -### disableAliases +###### disableLiveReload -**Default value:** false +(`bool`) Disable automatic live reloading of browser window. Default is `false`. -Will disable generation of alias redirects. Note that even if `disableAliases` is set, the aliases themselves are preserved on the page. The motivation with this is to be able to generate 301 redirects in an `.htaccess`, a Netlify `_redirects` file or similar using a custom output format. +###### disablePathToLower -### disableHugoGeneratorInject +(`bool`) Do not convert the url/path to lowercase. Default is `false`. -**Default value:** false +###### enableEmoji -Hugo will, by default, inject a generator meta tag in the HTML head on the _home page only_. You can turn it off, but we would really appreciate if you don't, as this is a good way to watch Hugo's popularity on the rise. +(`bool`) Enable Emoji emoticons support for page content; see the [emoji shortcode quick reference guide](/quick-reference/emojis/). Default is `false`. -### disableKinds +###### enableGitInfo -**Default value:** [] +(`bool`) Enable `.GitInfo` object for each page (if the Hugo site is versioned by Git). This will then update the `Lastmod` parameter for each page using the last git commit date for that content file. Default is `false`. -Enable disabling of all pages of the specified *Kinds*. Allowed values in this list: `"page"`, `"home"`, `"section"`, `"taxonomy"`, `"term"`, `"RSS"`, `"sitemap"`, `"robotsTXT"`, `"404"`. +###### enableMissingTranslationPlaceholders -### disableLiveReload +(`bool`) Show a placeholder instead of the default value or an empty string if a translation is missing. Default is `false`. -**Default value:** false +###### enableRobotsTXT -Disable automatic live reloading of browser window. +(`bool`) Enable generation of `robots.txt` file. Default is `false`. -### disablePathToLower - -**Default value:** false - -Do not convert the url/path to lowercase. - -### enableEmoji - -**Default value:** false - -Enable Emoji emoticons support for page content; see the [emoji shortcode quick reference guide](/quick-reference/emojis/). - -### enableGitInfo - -**Default value:** false - -Enable `.GitInfo` object for each page (if the Hugo site is versioned by Git). This will then update the `Lastmod` parameter for each page using the last git commit date for that content file. - -### enableInlineShortcodes - -**Default value:** false - -Enable inline shortcode support. See [Inline Shortcodes](/templates/shortcode-templates/#inline-shortcodes). - -### enableMissingTranslationPlaceholders - -**Default value:** false - -Show a placeholder instead of the default value or an empty string if a translation is missing. - -### enableRobotsTXT - -**Default value:** false - -Enable generation of `robots.txt` file. - -### frontmatter +###### frontmatter See [Front matter Configuration](#configure-front-matter). -### hasCJKLanguage +###### hasCJKLanguage -**Default value:** false +(`bool`) If true, auto-detect Chinese/Japanese/Korean Languages in the content. This will make `.Summary` and `.WordCount` behave correctly for CJK languages. Default is `false`. -If true, auto-detect Chinese/Japanese/Korean Languages in the content. This will make `.Summary` and `.WordCount` behave correctly for CJK languages. - -### imaging +###### imaging See [image processing configuration](/content-management/image-processing/#imaging-configuration). -### languageCode +###### languageCode -**Default value:** "" - -A language tag as defined by [RFC 5646](https://datatracker.ietf.org/doc/html/rfc5646). This value is used to populate: +(`string`) A language tag as defined by [RFC 5646](https://datatracker.ietf.org/doc/html/rfc5646). This value is used to populate: - The `` element in the internal [RSS template](https://github.com/gohugoio/hugo/blob/master/tpl/tplimpl/embedded/templates/_default/rss.xml) - The `lang` attribute of the `` element in the internal [alias template](https://github.com/gohugoio/hugo/blob/master/tpl/tplimpl/embedded/templates/alias.html) -### languages +###### languages See [Configure Languages](/content-management/multilingual/#configure-languages). -### disableLanguages +###### disableLanguages See [Disable a Language](/content-management/multilingual/#disable-a-language) -### markup +###### markup See [Configure Markup](/getting-started/configuration-markup). -### mediaTypes +###### mediaTypes See [Configure Media Types](/templates/output-formats/#media-types). -### menus +###### menus See [Menus](/content-management/menus/#define-in-site-configuration). -### minify +###### minify -See [Configure Minify](#configure-minify) +See [Configure Minify](#configure-minify). -### module +###### module Module configuration see [module configuration](/hugo-modules/configuration/). -### newContentEditor +###### newContentEditor -**Default value:** "" +(`string`) The editor to use when creating new content. -The editor to use when creating new content. +###### noChmod -### noChmod +(`bool`) Don't sync permission mode of files. Default is `false`. -**Default value:** false +###### noTimes -Don't sync permission mode of files. +(`bool`) Don't sync modification time of files. Default is `false`. -### noTimes - -**Default value:** false - -Don't sync modification time of files. - -### outputFormats +###### outputFormats See [Configure Output Formats](#configure-additional-output-formats). -### paginate +###### paginate -**Default value:** 10 +(`int`) Default number of elements per page in [pagination](/templates/pagination/). Default is `10`. -Default number of elements per page in [pagination](/templates/pagination/). +###### paginatePath -### paginatePath +(`string`) The path element used during pagination (`https://example.org/page/2`). Default is `page`. -**Default value:** "page" - -The path element used during pagination (`https://example.org/page/2`). - -### permalinks +###### permalinks See [Content Management](/content-management/urls/#permalinks). -### pluralizeListTitles +###### pluralizeListTitles -**Default value:** true +(`bool`) Pluralize titles in lists. Default is `true`. -Pluralize titles in lists. +###### publishDir -### publishDir +(`string`) The directory to where Hugo will write the final static site (the HTML files etc.). Default is `public`. -**Default value:** "public" - -The directory to where Hugo will write the final static site (the HTML files etc.). - -### related +###### related See [Related Content](/content-management/related/#configure-related-content). -### relativeURLs +###### relativeURLs -**Default value:** false +(`bool`) Enable this to make all relative URLs relative to content root. Note that this does not affect absolute URLs. Default is `false`. See [details](/content-management/urls/#relative-urls). -Enable this to make all relative URLs relative to content root. Note that this does not affect absolute URLs. See [details](/content-management/urls/#relative-urls). +###### refLinksErrorLevel -### refLinksErrorLevel +(`string`) When using `ref` or `relref` to resolve page links and a link cannot be resolved, it will be logged with this log level. Valid values are `ERROR` (default) or `WARNING`. Any `ERROR` will fail the build (`exit -1`). Default is `ERROR`. -**Default value:** "ERROR" +###### refLinksNotFoundURL -When using `ref` or `relref` to resolve page links and a link cannot be resolved, it will be logged with this log level. Valid values are `ERROR` (default) or `WARNING`. Any `ERROR` will fail the build (`exit -1`). +(`string`) URL to be used as a placeholder when a page reference cannot be found in `ref` or `relref`. Is used as-is. -### refLinksNotFoundURL +###### removePathAccents -URL to be used as a placeholder when a page reference cannot be found in `ref` or `relref`. Is used as-is. - -### removePathAccents - -**Default value:** false - -Removes [non-spacing marks](https://www.compart.com/en/unicode/category/Mn) from [composite characters](https://en.wikipedia.org/wiki/Precomposed_character) in content paths. +(`bool`) Removes [non-spacing marks](https://www.compart.com/en/unicode/category/Mn) from [composite characters](https://en.wikipedia.org/wiki/Precomposed_character) in content paths. Default is `false`. ```text content/post/hügó.md → https://example.org/post/hugo/ ``` -### sectionPagesMenu +###### sectionPagesMenu See [Menus](/content-management/menus/#define-automatically). -### security +###### security -See [Security Policy](/about/security-model/#security-policy) +See [Security Policy](/about/security-model/#security-policy). -### sitemap +###### sitemap Default [sitemap configuration](/templates/sitemap-template/#configuration). -### summaryLength +###### summaryLength -**Default value:** 70 +(`int`) The length of text in words to show in a [`.Summary`](/content-management/summaries/#automatic-summary-splitting). Default is `70`. -The length of text in words to show in a [`.Summary`](/content-management/summaries/#automatic-summary-splitting). - -### taxonomies +###### taxonomies See [Configure Taxonomies](/content-management/taxonomies#configure-taxonomies). -### theme +###### theme -: See [module configuration](/hugo-modules/configuration/#module-configuration-imports) for how to import a theme. +See [module configuration](/hugo-modules/configuration/#module-configuration-imports) for how to import a theme. -### themesDir +###### themesDir -**Default value:** "themes" +(`string`) The directory where Hugo reads the themes from. Default is `themes`. -The directory where Hugo reads the themes from. +###### timeout -### timeout +(`string`) Timeout for generating page contents, specified as a [duration](https://pkg.go.dev/time#Duration) or in seconds. *Note:* this is used to bail out of recursive content generation. You might need to raise this limit if your pages are slow to generate (e.g., because they require large image processing or depend on remote contents). Default is `30s`. -**Default value:** "30s" +###### timeZone -Timeout for generating page contents, specified as a [duration](https://pkg.go.dev/time#Duration) or in seconds. *Note:* this is used to bail out of recursive content generation. You might need to raise this limit if your pages are slow to generate (e.g., because they require large image processing or depend on remote contents). +(`string`) The time zone (or location), e.g. `Europe/Oslo`, used to parse front matter dates without such information and in the [`time`] function. The list of valid values may be system dependent, but should include `UTC`, `Local`, and any location in the [IANA Time Zone database](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones). -### timeZone +###### title -The time zone (or location), e.g. `Europe/Oslo`, used to parse front matter dates without such information and in the [`time`] function. The list of valid values may be system dependent, but should include `UTC`, `Local`, and any location in the [IANA Time Zone database](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones). +(`string`) Site title. -### title +###### titleCaseStyle -Site title. +(`string`) Default is `ap`. See [Configure Title Case](#configure-title-case). -### titleCaseStyle +###### uglyURLs -**Default value:** "ap" +(`bool`) When enabled, creates URL of the form `/filename.html` instead of `/filename/`. Default is `false`. -See [Configure Title Case](#configure-title-case) +###### watch -### uglyURLs - -**Default value:** false - -When enabled, creates URL of the form `/filename.html` instead of `/filename/`. - -### watch - -**Default value:** false - -Watch filesystem for changes and recreate as needed. +(`bool`) Watch filesystem for changes and recreate as needed. Default is `false`. {{% note %}} If you are developing your site on a \*nix machine, here is a handy shortcut for finding a configuration option from the command line: @@ -567,7 +539,7 @@ The `build.cachebusters` configuration option was added to support development u target = "$1" {{< /code-toggle >}} -Some key points in the above are `writeStats = true`, which writes a `hugo_stats.json` file on each build with HTML classes etc. that's used in the rendered output. Changes to this file will trigger a rebuild of the `styles.css` file. You also need to add `hugo_stats.json` to Hugo's server watcher. See [Hugo Starter Tailwind Basic](https://github.com/bep/hugo-starter-tailwind-basic) for a running example. +When `buildStats` {{< new-in 0.115.1 >}} is enabled, Hugo writes a `hugo_stats.json` file on each build with HTML classes etc. that's used in the rendered output. Changes to this file will trigger a rebuild of the `styles.css` file. You also need to add `hugo_stats.json` to Hugo's server watcher. See [Hugo Starter Tailwind Basic](https://github.com/bep/hugo-starter-tailwind-basic) for a running example. source : A regexp matching file(s) relative to one of the virtual component directories in Hugo, typically `assets/...`. @@ -664,35 +636,6 @@ none HUGO_NUMWORKERMULTIPLIER : Can be set to increase or reduce the number of workers used in parallel processing in Hugo. If not set, the number of logical CPUs will be used. -## Configuration lookup order - -Similar to the template [lookup order], Hugo has a default set of rules for searching for a configuration file in the root of your website's source directory as a default behavior: - -1. `./hugo.toml` -2. `./hugo.yaml` -3. `./hugo.json` - -In your configuration file, you can direct Hugo as to how you want your website rendered, control your website's menus, and arbitrarily define site-wide parameters specific to your project. - -## Example configuration - -The following is a typical example of a configuration file. The values nested under `params:` will populate the [`.Site.Params`] variable for use in [templates]: - -{{< code-toggle file=hugo >}} -baseURL: "https://yoursite.example.com/" -title: "My Hugo Site" -permalinks: - posts: /:year/:month/:title/ -params: - Subtitle: "Hugo is Absurdly Fast!" - AuthorName: "Jon Doe" - GitHubUser: "spf13" - ListOfFoo: - - "foo1" - - "foo2" - SidebarRecentLimit: 5 -{{< /code-toggle >}} - ## Configure with environment variables In addition to the 3 configuration options already mentioned, configuration key-values can be defined through operating system environment variables. @@ -789,6 +732,10 @@ Hugo v0.20 introduced the ability to render your content to multiple output form ## Configure minify +See the [tdewolff/minify] project page for details. + +[tdewolff/minify]: https://github.com/tdewolff/minify + Default configuration: {{< code-toggle config=minify />}} @@ -818,22 +765,6 @@ maxAge dir : (`string`) The absolute path to where the files for this cache will be stored. Allowed starting placeholders are `:cacheDir` and `:resourceDir` (see above). -## Configuration format specs - -- [TOML Spec][toml] -- [YAML Spec][yaml] -- [JSON Spec][json] - -[`.Site.Params`]: /variables/site/ -[directory structure]: /getting-started/directory-structure -[json]: https://www.ecma-international.org/publications/files/ECMA-ST/ECMA-404.pdf -[lookup order]: /templates/lookup-order/ -[Output Formats]: /templates/output-formats/ -[templates]: /templates/ -[toml]: https://toml.io/en/latest -[yaml]: https://yaml.org/spec/ -[static-files]: /content-management/static-files/ - ## Configure cacheDir This is the directory where Hugo by default will store its file caches. See [Configure File Caches](#configure-file-caches). @@ -849,3 +780,9 @@ If this is not set, Hugo will use, in order of preference: If you want to know the current value of `cacheDir`, you can run `hugo config`, e.g: `hugo config | grep cachedir`. [`time`]: /functions/time/astime +[`.Site.Params`]: /variables/site/ +[directory structure]: /getting-started/directory-structure +[lookup order]: /templates/lookup-order/ +[Output Formats]: /templates/output-formats/ +[templates]: /templates/ +[static-files]: /content-management/static-files/ diff --git a/content/en/getting-started/glossary.md b/content/en/getting-started/glossary.md index edf64ab89..929feb542 100644 --- a/content/en/getting-started/glossary.md +++ b/content/en/getting-started/glossary.md @@ -147,6 +147,16 @@ A numeric data type without a fractional component. For example, `42`. Software design and development efforts that enable [localization](#localization). See the [W3C definition](https://www.w3.org/International/questions/qa-i18n). Abbreviated i18n. +###### interval + +An [interval](https://en.wikipedia.org/wiki/Interval_(mathematics)) is a range of numbers between two endpoints: closed, open, or half-open. + +- A _closed_ interval, denoted by brackets, includes its endpoints. For example, [0, 1] is the interval where `0 <= x <= 1`. + +- An _open_ interval, denoted by parentheses, excludes its endpoints. For example, (0, 1) is the interval where `0 < x < 1`. + +- A _half-open_ interval includes only one of its endpoints. For example, (0, 1] is the _left-open_ interval where `0 < x <= 1`, while [0, 1) is the _right-open_ interval where `0 <= x < 1`. + ###### kind See [page kind](#page-kind). @@ -206,6 +216,10 @@ Created by invoking the [`Alphabetical`] or [`ByCount`] method on a [taxonomy ob A directory that encapsulates both content and associated [resources](#resource). There are two types of page bundles: [leaf bundles](#leaf-bundle) and [branch bundles](#branch-bundle). See [details](/content-management/page-bundles/). +###### page collection + +A slice of page objects. + ###### page kind A classification of pages, one of `home`, `page`, `section`, `taxonomy`, or `term`. See [details](/templates/section-templates/#page-kinds). diff --git a/content/en/getting-started/quick-start.md b/content/en/getting-started/quick-start.md index ce4312455..a6c54b54c 100644 --- a/content/en/getting-started/quick-start.md +++ b/content/en/getting-started/quick-start.md @@ -10,6 +10,7 @@ menu: weight: 20 toc: true aliases: [/quickstart/,/overview/quickstart/] +minVersion: v0.112.0 --- In this tutorial you will: @@ -23,7 +24,7 @@ In this tutorial you will: Before you begin this tutorial you must: -1. [Install Hugo] (extended edition, v0.112.0 or later) +1. [Install Hugo] (extended edition, {{% param "minVersion" %}} or later) 1. [Install Git] You must also be comfortable working from the command line. @@ -45,6 +46,12 @@ PowerShell and Windows PowerShell [are different applications]. [are different applications]: https://learn.microsoft.com/en-us/powershell/scripting/whats-new/differences-from-windows-powershell?view=powershell-7.3 {{% /note %}} +Verify that you have installed Hugo {{% param "minVersion" %}} or later. + +```text +hugo version +``` + Run these commands to create a Hugo site with the [Ananke] theme. The next section provides an explanation of each command. ```text @@ -109,11 +116,11 @@ hugo new content posts/my-first-post.md Hugo created the file in the `content/posts` directory. Open the file with your editor. ```text ---- -title: "My First Post" -date: 2022-11-20T09:03:20-08:00 -draft: true ---- ++++ +title = 'My First Post' +date = 2024-01-14T07:07:07+01:00 +draft = true ++++ ``` Notice the `draft` value in the [front matter] is `true`. By default, Hugo does not publish draft content when you build the site. Learn more about [draft, future, and expired content]. @@ -123,11 +130,11 @@ Add some [markdown] to the body of the post, but do not change the `draft` value [markdown]: https://commonmark.org/help/ ```text ---- -title: "My First Post" -date: 2022-11-20T09:03:20-08:00 -draft: true ---- ++++ +title = 'My First Post' +date = 2024-01-14T07:07:07+01:00 +draft = true ++++ ## Introduction This is **bold** text, and this is *emphasized* text. diff --git a/content/en/hosting-and-deployment/hosting-on-github/index.md b/content/en/hosting-and-deployment/hosting-on-github/index.md index f41250279..24bd31a25 100644 --- a/content/en/hosting-and-deployment/hosting-on-github/index.md +++ b/content/en/hosting-and-deployment/hosting-on-github/index.md @@ -99,7 +99,7 @@ jobs: build: runs-on: ubuntu-latest env: - HUGO_VERSION: 0.120.2 + HUGO_VERSION: 0.121.0 steps: - name: Install Hugo CLI run: | @@ -114,7 +114,7 @@ jobs: fetch-depth: 0 - name: Setup Pages id: pages - uses: actions/configure-pages@v3 + uses: actions/configure-pages@v4 - name: Install Node.js dependencies run: "[[ -f package-lock.json || -f npm-shrinkwrap.json ]] && npm ci || true" - name: Build with Hugo @@ -142,7 +142,7 @@ jobs: steps: - name: Deploy to GitHub Pages id: deployment - uses: actions/deploy-pages@v2 + uses: actions/deploy-pages@v3 {{< /code >}} Step 7 diff --git a/content/en/hosting-and-deployment/hosting-on-gitlab.md b/content/en/hosting-and-deployment/hosting-on-gitlab.md index dce306253..74b1fa154 100644 --- a/content/en/hosting-and-deployment/hosting-on-gitlab.md +++ b/content/en/hosting-and-deployment/hosting-on-gitlab.md @@ -27,8 +27,8 @@ Define your [CI/CD](https://docs.gitlab.com/ee/ci/quick_start/) jobs by creating {{< code file=.gitlab-ci.yml copy=true >}} variables: - DART_SASS_VERSION: 1.64.1 - HUGO_VERSION: 0.115.4 + DART_SASS_VERSION: 1.69.5 + HUGO_VERSION: 0.121.0 NODE_VERSION: 20.x GIT_DEPTH: 0 GIT_STRATEGY: clone diff --git a/content/en/hosting-and-deployment/hosting-on-netlify.md b/content/en/hosting-and-deployment/hosting-on-netlify.md index 9b01f4cd8..ac6202700 100644 --- a/content/en/hosting-and-deployment/hosting-on-netlify.md +++ b/content/en/hosting-and-deployment/hosting-on-netlify.md @@ -57,14 +57,14 @@ For production: {{< code file=netlify.toml >}} [context.production.environment] - HUGO_VERSION = "0.115.4" + HUGO_VERSION = "0.121.0" {{< /code >}} For testing: {{< code file=netlify.toml >}} [context.deploy-preview.environment] - HUGO_VERSION = "0.115.4" + HUGO_VERSION = "0.121.0" {{< /code >}} The Netlify configuration file can be a little hard to understand and get right for the different environment, and you may get some inspiration and tips from this site's `netlify.toml`: diff --git a/content/en/hugo-modules/configuration.md b/content/en/hugo-modules/configuration.md index d707e7498..ce9e97d81 100644 --- a/content/en/hugo-modules/configuration.md +++ b/content/en/hugo-modules/configuration.md @@ -15,29 +15,30 @@ toc: true {{< code-toggle file=hugo >}} [module] -noVendor = "" -proxy = "direct" -noProxy = "none" -private = "*.*" -replacements = "" -workspace = "off" +noProxy = 'none' +noVendor = '' +private = '*.*' +proxy = 'direct' +replacements = '' +vendorClosest = false +workspace = 'off' {{< /code-toggle >}} -noVendor -: A optional Glob pattern matching module paths to skip when vendoring, e.g. "github.com/**" - -vendorClosest -: When enabled, we will pick the vendored module closest to the module using it. The default behavior is to pick the first. Note that there can still be only one dependency of a given module path, so once it is in use it cannot be redefined. - -proxy -: Defines the proxy server to use to download remote modules. Default is `direct`, which means "git clone" and similar. - noProxy : Comma separated glob list matching paths that should not use the proxy configured above. +noVendor +: A optional Glob pattern matching module paths to skip when vendoring, e.g. "github.com/**" + private : Comma separated glob list matching paths that should be treated as private. +proxy +: Defines the proxy server to use to download remote modules. Default is `direct`, which means "git clone" and similar. + +vendorClosest +: When enabled, we will pick the vendored module closest to the module using it. The default behavior is to pick the first. Note that there can still be only one dependency of a given module path, so once it is in use it cannot be redefined. + workspace : The workspace file to use. This enables Go workspace mode. Note that this can also be set via OS env, e.g. `export HUGO_MODULE_WORKSPACE=/my/hugo.work` This only works with Go 1.18+. In Hugo `v0.109.0` we changed the default to `off` and we now resolve any relative work file names relative to the working directory. diff --git a/content/en/hugo-modules/use-modules.md b/content/en/hugo-modules/use-modules.md index 9e8f1d4d0..295ff2061 100644 --- a/content/en/hugo-modules/use-modules.md +++ b/content/en/hugo-modules/use-modules.md @@ -144,7 +144,7 @@ A workspace can be configured in a `*.work` file and activated with the [module. See the [hugo.work](https://github.com/gohugoio/hugo/blob/master/docs/hugo.work) file in the Hugo Docs repo for an example: ```text -go 1.19 +go 1.20 use . use ../gohugoioTheme diff --git a/content/en/hugo-pipes/babel.md b/content/en/hugo-pipes/babel.md index 73ccf01d4..c447983a9 100755 --- a/content/en/hugo-pipes/babel.md +++ b/content/en/hugo-pipes/babel.md @@ -24,7 +24,7 @@ Hugo Pipe's Babel requires the `@babel/cli` and `@babel/core` JavaScript package If you are using the Hugo Snap package, Babel and plugin(s) need to be installed locally within your Hugo site directory, e.g., `npm install @babel/cli @babel/core --save-dev` without the `-g` flag. {{% /note %}} -### configuration +## Configuration We add the main project's `node_modules` to `NODE_PATH` when running Babel and similar tools. There are some known [issues](https://github.com/babel/babel/issues/5618) with Babel in this area, so if you have a `babel.config.js` living in a Hugo Module (and not in the project itself), we recommend using `require` to load the presets/plugins, e.g.: @@ -42,7 +42,7 @@ module.exports = { }; ``` -### Options +## Options config : (`string`) Path to the Babel configuration file. Hugo will, by default, look for a `babel.config.js` in your project. More information on these configuration files can be found here: [babel configuration](https://babeljs.io/docs/en/configuration). @@ -62,7 +62,7 @@ verbose sourceMap : (`string`) Output `inline` or `external` sourcemap from the babel compile. External sourcemaps will be written to the target with the output file name + ".map". Input sourcemaps can be read from js.Build and node modules and combined into the output sourcemaps. -### Examples +## Examples ```go-html-template {{- $transpiled := resources.Get "scripts/main.js" | babel -}} diff --git a/content/en/hugo-pipes/js.md b/content/en/hugo-pipes/js.md index c9366ce8a..9d2bbbd82 100644 --- a/content/en/hugo-pipes/js.md +++ b/content/en/hugo-pipes/js.md @@ -25,7 +25,7 @@ targetPath : (`string`) If not set, the source path will be used as the base target path. Note that the target path's extension may change if the target MIME type is different, e.g. when the source is TypeScript. -params +params {{< new-in "0.96.0" >}} : (`map` or `slice`) Params that can be imported as JSON in your JS files, e.g.: ```go-html-template diff --git a/content/en/hugo-pipes/minification.md b/content/en/hugo-pipes/minification.md index f8cedcde5..a5d4724f9 100755 --- a/content/en/hugo-pipes/minification.md +++ b/content/en/hugo-pipes/minification.md @@ -17,7 +17,7 @@ action: ## Usage -Any CSS, JS, JSON, HTML, SVG or XML resource can be minified using `resources.Minify` which takes for argument the resource object. +Any CSS, JS, JSON, HTML, SVG, or XML resource can be minified using `resources.Minify` which takes for argument the resource object. ```go-html-template {{ $css := resources.Get "css/main.css" }} diff --git a/content/en/installation/_common/04-build-from-source.md b/content/en/installation/_common/04-build-from-source.md index f670a5752..63be3e456 100644 --- a/content/en/installation/_common/04-build-from-source.md +++ b/content/en/installation/_common/04-build-from-source.md @@ -7,7 +7,7 @@ To build the extended edition of Hugo from source you must: 1. Install [Git] -1. Install [Go] version 1.19 or later +1. Install [Go] version 1.20 or later 1. Install a C compiler, either [GCC] or [Clang] 1. Update your `PATH` environment variable as described in the [Go documentation] diff --git a/content/en/installation/_common/homebrew.md b/content/en/installation/_common/homebrew.md index 8d6ff90fc..6cd7a524f 100644 --- a/content/en/installation/_common/homebrew.md +++ b/content/en/installation/_common/homebrew.md @@ -4,7 +4,7 @@ ### Homebrew -[Homebrew] is a free and open-source package manager for macOS and Linux. This will install the extended edition of Hugo: +[Homebrew] is a free and open-source package manager for macOS and Linux. To install the extended edition of Hugo: ```sh brew install hugo diff --git a/content/en/installation/bsd.md b/content/en/installation/bsd.md index a3b179d25..6d00b8b98 100644 --- a/content/en/installation/bsd.md +++ b/content/en/installation/bsd.md @@ -24,7 +24,7 @@ Most BSD derivatives maintain a repository for commonly installed applications. ### DragonFly BSD -[DragonFly BSD] includes Hugo in its package repository. This will install the extended edition of Hugo: +[DragonFly BSD] includes Hugo in its package repository. To install the extended edition of Hugo: ```sh sudo pkg install gohugo @@ -34,7 +34,7 @@ sudo pkg install gohugo ### FreeBSD -[FreeBSD] includes Hugo in its package repository. This will install the extended edition of Hugo: +[FreeBSD] includes Hugo in its package repository. To install the extended edition of Hugo: ```sh sudo pkg install gohugo @@ -44,7 +44,7 @@ sudo pkg install gohugo ### NetBSD -[NetBSD] includes Hugo in its package repository. This will install the extended edition of Hugo: +[NetBSD] includes Hugo in its package repository. To install the extended edition of Hugo: ```sh sudo pkgin install go-hugo diff --git a/content/en/installation/linux.md b/content/en/installation/linux.md index bb8f4b555..7b75f149b 100644 --- a/content/en/installation/linux.md +++ b/content/en/installation/linux.md @@ -24,7 +24,7 @@ toc: true The Hugo snap package is [strictly confined]. Strictly confined snaps run in complete isolation, up to a minimal access level that’s deemed always safe. The sites you create and build must be located within your home directory, or on removable media. -This will install the extended edition of Hugo: +To install the extended edition of Hugo: ```sh sudo snap install hugo @@ -55,14 +55,26 @@ sudo snap disconnect hugo:ssh-keys Most Linux distributions maintain a repository for commonly installed applications. {{% note %}} -Due to Long Term Release (LTR) guidelines, most Linux package repositories will not contain the [latest release]. +The Hugo version available in package repositories varies based on Linux distribution and release, and in some cases will not be the [latest version]. -[latest release]: https://github.com/gohugoio/hugo/releases/latest +Use one of the other installation methods if your package repository does not provide the desired version. + +[latest version]: https://github.com/gohugoio/hugo/releases/latest {{% /note %}} +### Alpine Linux + +To install the extended edition of Hugo on [Alpine Linux]: + +```sh +doas apk add --no-cache --repository=https://dl-cdn.alpinelinux.org/alpine/edge/community hugo +``` + +[Alpine Linux]: https://alpinelinux.org/ + ### Arch Linux -Derivatives of the [Arch Linux] distribution of Linux include [EndeavourOS], [Garuda Linux], [Manjaro], and others. This will install the extended edition of Hugo: +Derivatives of the [Arch Linux] distribution of Linux include [EndeavourOS], [Garuda Linux], [Manjaro], and others. To install the extended edition of Hugo: ```sh sudo pacman -S hugo @@ -75,7 +87,7 @@ sudo pacman -S hugo ### Debian -Derivatives of the [Debian] distribution of Linux include [elementary OS], [KDE neon], [Linux Lite], [Linux Mint], [MX Linux], [Pop!_OS], [Ubuntu], [Zorin OS], and others. This will install the extended edition of Hugo: +Derivatives of the [Debian] distribution of Linux include [elementary OS], [KDE neon], [Linux Lite], [Linux Mint], [MX Linux], [Pop!_OS], [Ubuntu], [Zorin OS], and others. To install the extended edition of Hugo: ```sh sudo apt install hugo @@ -95,7 +107,7 @@ You can also download Debian packages from the [latest release] page. ### Fedora -Derivatives of the [Fedora] distribution of Linux include [CentOS], [Red Hat Enterprise Linux], and others. This will install the extended edition of Hugo: +Derivatives of the [Fedora] distribution of Linux include [CentOS], [Red Hat Enterprise Linux], and others. To install the extended edition of Hugo: ```sh sudo dnf install hugo @@ -105,9 +117,30 @@ sudo dnf install hugo [Fedora]: https://getfedora.org/ [Red Hat Enterprise Linux]: https://www.redhat.com/ +### Gentoo + +Derivatives of the [Gentoo] distribution of Linux include [Calculate Linux], [Funtoo], and others. Follow the instructions below to install the extended edition of Hugo: + +1. Specify the `extended` [USE] flag in /etc/portage/package.use/hugo: + + ```text + www-apps/hugo extended + ``` + +2. Build using the Portage package manager: + + ```sh + sudo emerge www-apps/hugo + ``` + +[Calculate Linux]: https://www.calculate-linux.org/ +[Funtoo]: https://www.funtoo.org/ +[Gentoo]: https://www.gentoo.org/ +[USE]: https://packages.gentoo.org/packages/www-apps/hugo + ### openSUSE -Derivatives of the [openSUSE] distribution of Linux include [GeckoLinux], [Linux Karmada], and others. This will install the extended edition of Hugo: +Derivatives of the [openSUSE] distribution of Linux include [GeckoLinux], [Linux Karmada], and others. To install the extended edition of Hugo: ```sh sudo zypper install hugo @@ -119,7 +152,7 @@ sudo zypper install hugo ### Solus -The [Solus] distribution of Linux includes Hugo in its package repository. This will install the _standard_ edition of Hugo: +The [Solus] distribution of Linux includes Hugo in its package repository. To install the extended edition of Hugo: ```sh sudo eopkg install hugo diff --git a/content/en/installation/macos.md b/content/en/installation/macos.md index eba977481..fa6029679 100644 --- a/content/en/installation/macos.md +++ b/content/en/installation/macos.md @@ -22,7 +22,7 @@ toc: true ### MacPorts -[MacPorts] is a free and open-source package manager for macOS. This will install the extended edition of Hugo: +[MacPorts] is a free and open-source package manager for macOS. To install the extended edition of Hugo: ```sh sudo port install hugo diff --git a/content/en/installation/windows.md b/content/en/installation/windows.md index 97e767af8..719264550 100644 --- a/content/en/installation/windows.md +++ b/content/en/installation/windows.md @@ -10,6 +10,11 @@ menu: weight: 40 toc: true --- + +{{% note %}} +Hugo v0.121.1 and later require at least Windows 10 or Windows Server 2016. +{{% /note %}} + {{% include "installation/_common/01-editions.md" %}} {{% include "installation/_common/02-prerequisites.md" %}} @@ -20,7 +25,7 @@ toc: true ### Chocolatey -[Chocolatey] is a free and open-source package manager for Windows. This will install the extended edition of Hugo: +[Chocolatey] is a free and open-source package manager for Windows. To install the extended edition of Hugo: ```sh choco install hugo-extended @@ -30,7 +35,7 @@ choco install hugo-extended ### Scoop -[Scoop] is a free and open-source package manager for Windows. This will install the extended edition of Hugo: +[Scoop] is a free and open-source package manager for Windows. To install the extended edition of Hugo: ```sh scoop install hugo-extended @@ -40,7 +45,7 @@ scoop install hugo-extended ### Winget -[Winget] is Microsoft's official free and open-source package manager for Windows. This will install the extended edition of Hugo: +[Winget] is Microsoft's official free and open-source package manager for Windows. To install the extended edition of Hugo: ```sh winget install Hugo.Hugo.Extended diff --git a/content/en/methods/menu-entry/Children.md b/content/en/methods/menu-entry/Children.md index af2af6dce..ad671b2d0 100644 --- a/content/en/methods/menu-entry/Children.md +++ b/content/en/methods/menu-entry/Children.md @@ -15,18 +15,18 @@ Use the `Children` method when rendering a nested menu. With this site configuration: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] name = 'Products' pageRef = '/product' weight = 10 -[[menu.main]] +[[menus.main]] name = 'Product 1' pageRef = '/products/product-1' parent = 'Products' weight = 1 -[[menu.main]] +[[menus.main]] name = 'Product 2' pageRef = '/products/product-2' parent = 'Products' diff --git a/content/en/methods/menu-entry/HasChildren.md b/content/en/methods/menu-entry/HasChildren.md index d906987e8..fac03b7ae 100644 --- a/content/en/methods/menu-entry/HasChildren.md +++ b/content/en/methods/menu-entry/HasChildren.md @@ -15,18 +15,18 @@ Use the `HasChildren` method when rendering a nested menu. With this site configuration: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] name = 'Products' pageRef = '/product' weight = 10 -[[menu.main]] +[[menus.main]] name = 'Product 1' pageRef = '/products/product-1' parent = 'Products' weight = 1 -[[menu.main]] +[[menus.main]] name = 'Product 2' pageRef = '/products/product-2' parent = 'Products' diff --git a/content/en/methods/menu-entry/Identifier.md b/content/en/methods/menu-entry/Identifier.md index a4d7e129e..ba8b77ece 100644 --- a/content/en/methods/menu-entry/Identifier.md +++ b/content/en/methods/menu-entry/Identifier.md @@ -14,13 +14,13 @@ The `Identifier` method returns the `identifier` property of the menu entry. If [automatically]: /content-management/menus/#define-automatically {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] identifier = 'about' name = 'About' pageRef = '/about' weight = 10 -[[menu.main]] +[[menus.main]] identifier = 'contact' name = 'Contact' pageRef = '/contact' diff --git a/content/en/methods/menu-entry/KeyName.md b/content/en/methods/menu-entry/KeyName.md index 8031441b9..4b43596b0 100644 --- a/content/en/methods/menu-entry/KeyName.md +++ b/content/en/methods/menu-entry/KeyName.md @@ -12,13 +12,13 @@ action: In this menu definition, the second entry does not contain an `identifier`, so the `Identifier` method returns its `name` property instead: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] identifier = 'about' name = 'About' pageRef = '/about' weight = 10 -[[menu.main]] +[[menus.main]] name = 'Contact' pageRef = '/contact' weight = 20 diff --git a/content/en/methods/menu-entry/Page.md b/content/en/methods/menu-entry/Page.md index 9b23f7b73..b75e4af55 100644 --- a/content/en/methods/menu-entry/Page.md +++ b/content/en/methods/menu-entry/Page.md @@ -5,7 +5,7 @@ categories: [] keywords: [] action: related: [] - returnType: hugolib.pageState + returnType: page.Page signatures: [MENUENTRY.Page] --- @@ -14,15 +14,15 @@ Regardless of how you [define menu entries], an entry associated with a page has In this menu definition, the first two entries are associated with a page, the last entry is not: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] pageRef = '/about' weight = 10 -[[menu.main]] +[[menus.main]] pageRef = '/contact' weight = 20 -[[menu.main]] +[[menus.main]] name = 'Hugo' url = 'https://gohugo.io' weight = 30 diff --git a/content/en/methods/menu-entry/Params.md b/content/en/methods/menu-entry/Params.md index 1486c12cb..8af3f0637 100644 --- a/content/en/methods/menu-entry/Params.md +++ b/content/en/methods/menu-entry/Params.md @@ -12,21 +12,21 @@ action: When you define menu entries [in site configuration] or [in front matter], you can include a `params` key to attach additional information to the entry. For example: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] name = 'About' pageRef = '/about' weight = 10 -[[menu.main]] +[[menus.main]] name = 'Contact' pageRef = '/contact' weight = 20 -[[menu.main]] +[[menus.main]] name = 'Hugo' url = 'https://gohugo.io' weight = 30 -[menu.main.params] +[menus.main.params] rel = 'external' {{< /code-toggle >}} diff --git a/content/en/methods/menu-entry/Parent.md b/content/en/methods/menu-entry/Parent.md index 897712831..af1b4afe6 100644 --- a/content/en/methods/menu-entry/Parent.md +++ b/content/en/methods/menu-entry/Parent.md @@ -12,19 +12,18 @@ action: With this menu definition: {{< code-toggle file=hugo >}} -[menu] -[[menu.main]] +[[menus.main]] name = 'Products' pageRef = '/product' weight = 10 -[[menu.main]] +[[menus.main]] name = 'Product 1' pageRef = '/products/product-1' parent = 'Products' weight = 1 -[[menu.main]] +[[menus.main]] name = 'Product 2' pageRef = '/products/product-2' parent = 'Products' diff --git a/content/en/methods/menu-entry/_common/pre-post.md b/content/en/methods/menu-entry/_common/pre-post.md index 8cc787ea9..fbfce062a 100644 --- a/content/en/methods/menu-entry/_common/pre-post.md +++ b/content/en/methods/menu-entry/_common/pre-post.md @@ -7,14 +7,14 @@ In this site configuration we enable rendering of [emoji shortcodes], and add em {{< code-toggle file=hugo >}} enableEmoji = true -[[menu.main]] +[[menus.main]] name = 'About' pageRef = '/about' post = ':point_left:' pre = ':point_right:' weight = 10 -[[menu.main]] +[[menus.main]] name = 'Contact' pageRef = '/contact' post = ':arrow_left:' diff --git a/content/en/methods/menu/ByName.md b/content/en/methods/menu/ByName.md index 3f1c52b2e..04f25c22d 100644 --- a/content/en/methods/menu/ByName.md +++ b/content/en/methods/menu/ByName.md @@ -14,17 +14,17 @@ The `Sort` method returns the given menu with its entries sorted by `name`. Consider this menu definition: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] name = 'Services' pageRef = '/services' weight = 10 -[[menu.main]] +[[menus.main]] name = 'About' pageRef = '/about' weight = 20 -[[menu.main]] +[[menus.main]] name = 'Contact' pageRef = '/contact' weight = 30 diff --git a/content/en/methods/menu/ByWeight.md b/content/en/methods/menu/ByWeight.md index c915914db..d5cb0444b 100644 --- a/content/en/methods/menu/ByWeight.md +++ b/content/en/methods/menu/ByWeight.md @@ -16,19 +16,19 @@ The `ByWeight` method returns the given menu with its entries sorted by [`weight Consider this menu definition: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] identifier = 'about' name = 'About' pageRef = '/about' weight = 20 -[[menu.main]] +[[menus.main]] identifier = 'services' name = 'Services' pageRef = '/services' weight = 10 -[[menu.main]] +[[menus.main]] identifier = 'contact' name = 'Contact' pageRef = '/contact' diff --git a/content/en/methods/menu/Limit.md b/content/en/methods/menu/Limit.md index 12263e811..23a523dbd 100644 --- a/content/en/methods/menu/Limit.md +++ b/content/en/methods/menu/Limit.md @@ -14,17 +14,17 @@ The `Limit` method returns the given menu, limited to the first N entries. Consider this menu definition: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] name = 'Services' pageRef = '/services' weight = 10 -[[menu.main]] +[[menus.main]] name = 'About' pageRef = '/about' weight = 20 -[[menu.main]] +[[menus.main]] name = 'Contact' pageRef = '/contact' weight = 30 diff --git a/content/en/methods/menu/Reverse.md b/content/en/methods/menu/Reverse.md index 989132d60..a3fe09dce 100644 --- a/content/en/methods/menu/Reverse.md +++ b/content/en/methods/menu/Reverse.md @@ -14,17 +14,17 @@ The `Reverse` method returns the given menu, reversing the sort order of its ent Consider this menu definition: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] name = 'Services' pageRef = '/services' weight = 10 -[[menu.main]] +[[menus.main]] name = 'About' pageRef = '/about' weight = 20 -[[menu.main]] +[[menus.main]] name = 'Contact' pageRef = '/contact' weight = 30 diff --git a/content/en/methods/page/AllTranslations.md b/content/en/methods/page/AllTranslations.md index b9c156127..b8cc65179 100644 --- a/content/en/methods/page/AllTranslations.md +++ b/content/en/methods/page/AllTranslations.md @@ -63,8 +63,9 @@ And this template: {{ with .AllTranslations }} {{ end }} @@ -74,9 +75,9 @@ Hugo will render this list on the "Book 1" page of each site: ```html ``` @@ -84,7 +85,7 @@ On the "Book 2" page of the English and German sites, Hugo will render this: ```html ``` diff --git a/content/en/methods/page/CodeOwners.md b/content/en/methods/page/CodeOwners.md index ec7e5c8bf..068c4591f 100644 --- a/content/en/methods/page/CodeOwners.md +++ b/content/en/methods/page/CodeOwners.md @@ -29,7 +29,7 @@ enableGitInfo = true Consider this project structure: ```text -hugo-testing/ +my-project/ ├── content/ │ ├── books/ │ │ └── les-miserables.md diff --git a/content/en/methods/page/CurrentSection.md b/content/en/methods/page/CurrentSection.md index 03cb9eb3d..7049feb47 100644 --- a/content/en/methods/page/CurrentSection.md +++ b/content/en/methods/page/CurrentSection.md @@ -12,7 +12,7 @@ action: - methods/page/IsDescendant - methods/page/Parent - methods/page/Sections - returnType: hugolib.pageState + returnType: page.Page signatures: [PAGE.CurrentSection] --- diff --git a/content/en/methods/page/File.md b/content/en/methods/page/File.md index c39d1a64d..44b752215 100644 --- a/content/en/methods/page/File.md +++ b/content/en/methods/page/File.md @@ -30,8 +30,9 @@ Code defensively by verifying file existence as shown in each of the examples be The path separators (slash or backslash) in `Path`, `Dir`, and `Filename` depend on the operating system. {{% /note %}} -BaseFileName -: (`string`) The file name, excluding the extension. +###### BaseFileName + +(`string`) The file name, excluding the extension. ```go-html-template {{ with .File }} @@ -39,8 +40,9 @@ BaseFileName {{ end }} ``` -ContentBaseName -: (`string`) If the page is a branch or leaf bundle, the name of the containing directory, else the `TranslationBaseName`. +###### ContentBaseName + +(`string`) If the page is a branch or leaf bundle, the name of the containing directory, else the `TranslationBaseName`. ```go-html-template {{ with .File }} @@ -48,8 +50,9 @@ ContentBaseName {{ end }} ``` -Dir -: (`string`) The file path, excluding the file name, relative to the `content` directory. +###### Dir + +(`string`) The file path, excluding the file name, relative to the `content` directory. ```go-html-template {{ with .File }} @@ -57,8 +60,9 @@ Dir {{ end }} ``` -Ext -: (`string`) The file extension. +###### Ext + +(`string`) The file extension. ```go-html-template {{ with .File }} @@ -66,8 +70,9 @@ Ext {{ end }} ``` -Filename -: (`string`) The absolute file path. +###### Filename + +(`string`) The absolute file path. ```go-html-template {{ with .File }} @@ -75,8 +80,9 @@ Filename {{ end }} ``` -Lang -: (`string`) The language associated with the given file. +###### Lang + +(`string`) The language associated with the given file. ```go-html-template {{ with .File }} @@ -84,8 +90,9 @@ Lang {{ end }} ``` -LogicalName -: (`string`) The file name. +###### LogicalName + +(`string`) The file name. ```go-html-template {{ with .File }} @@ -93,8 +100,9 @@ LogicalName {{ end }} ``` -Path -: (`string`) The file path, relative to the `content` directory. +###### Path + +(`string`) The file path, relative to the `content` directory. ```go-html-template {{ with .File }} @@ -102,8 +110,9 @@ Path {{ end }} ``` -TranslationBaseName -: (`string`) The file name, excluding the extension and language identifier. +###### TranslationBaseName + +(`string`) The file name, excluding the extension and language identifier. ```go-html-template {{ with .File }} @@ -111,8 +120,9 @@ TranslationBaseName {{ end }} ``` -UniqueID -: (`string`) The MD5 hash of `.File.Path`. +###### UniqueID + +(`string`) The MD5 hash of `.File.Path`. ```go-html-template {{ with .File }} diff --git a/content/en/methods/page/FirstSection.md b/content/en/methods/page/FirstSection.md index f757aa2d2..b3ae4c04a 100644 --- a/content/en/methods/page/FirstSection.md +++ b/content/en/methods/page/FirstSection.md @@ -12,7 +12,7 @@ action: - methods/page/IsDescendant - methods/page/Parent - methods/page/Sections - returnType: hugolib.pageState + returnType: page.Page signatures: [PAGE.FirstSection] --- diff --git a/content/en/methods/page/Fragments.md b/content/en/methods/page/Fragments.md index bae1c7d03..89f82d2ce 100644 --- a/content/en/methods/page/Fragments.md +++ b/content/en/methods/page/Fragments.md @@ -28,14 +28,14 @@ Use the `Fragments` method on a `Page` object to create a table of contents with ## Methods Headings -: (`map`) A nested map of all headings on the page. Each map contains the following keys: `ID`, `Title` and `Headings`. To inspect the data structure: +: (`map`) A nested map of all headings on the page. Each map contains the following keys: `ID`, `Level`, `Title` and `Headings`. To inspect the data structure: ```go-html-template
{{ .Fragments.Headings | jsonify (dict "indent" "  ") }}
``` HeadingsMap -: (`slice`) A slice of maps of all headings on the page, with first-level keys for each heading. Each map contains the following keys: `ID`, `Title` and `Headings`. To inspect the data structure: +: (`slice`) A slice of maps of all headings on the page, with first-level keys for each heading. Each map contains the following keys: `ID`, `Level`, `Title` and `Headings`. To inspect the data structure: ```go-html-template
{{ .Fragments.HeadingsMap | jsonify (dict "indent" "  ") }}
diff --git a/content/en/methods/page/GetPage.md b/content/en/methods/page/GetPage.md index ed072932a..b1f192d58 100644 --- a/content/en/methods/page/GetPage.md +++ b/content/en/methods/page/GetPage.md @@ -6,7 +6,7 @@ keywords: [] action: related: - methods/site/GetPage - returnType: hugolib.pageState + returnType: page.Page signatures: [PAGE.GetPage PATH] aliases: [/functions/getpage] --- diff --git a/content/en/methods/page/GitInfo.md b/content/en/methods/page/GitInfo.md index 88137614c..9dba2a2b2 100644 --- a/content/en/methods/page/GitInfo.md +++ b/content/en/methods/page/GitInfo.md @@ -34,7 +34,7 @@ hugo --enableGitInfo ``` {{% note %}} -When you set `enableGitInto` to `true`, or enable the feature with the command line flag, the last modification date for each content page will be the Author Date of the last commit for that file. +When you set `enableGitInfo` to `true`, or enable the feature with the command line flag, the last modification date for each content page will be the Author Date of the last commit for that file. This is configurable. See [details]. @@ -43,8 +43,9 @@ This is configurable. See [details]. ## Methods -AbbreviatedHash -: (`string`) The abbreviated commit hash. +###### AbbreviatedHash + +(`string`) The abbreviated commit hash. ```go-html-template {{ with .GitInfo }} @@ -52,8 +53,9 @@ AbbreviatedHash {{ end }} ``` -AuthorDate -: (`time.Time`) The author date. +###### AuthorDate + +(`time.Time`) The author date. ```go-html-template {{ with .GitInfo }} @@ -61,8 +63,9 @@ AuthorDate {{ end }} ``` -AuthorEmail -: (`string`) The author's email address, respecting [gitmailmap]. +###### AuthorEmail + +(`string`) The author's email address, respecting [gitmailmap]. ```go-html-template {{ with .GitInfo }} @@ -70,8 +73,9 @@ AuthorEmail {{ end }} ``` -AuthorName -: (`string`) The author's name, respecting [gitmailmap]. +###### AuthorName + +(`string`) The author's name, respecting [gitmailmap]. ```go-html-template {{ with .GitInfo }} @@ -79,8 +83,19 @@ AuthorName {{ end }} ``` -Hash -: (`string`) The commit hash. +###### CommitDate + +(`time.Time`) The commit date. + +```go-html-template +{{ with .GitInfo }} + {{ .CommitDate.Format "2006-01-02" }} → 2023-10-09 +{{ end }} +``` + +###### Hash + +(`string`) The commit hash. ```go-html-template {{ with .GitInfo }} @@ -88,8 +103,9 @@ Hash {{ end }} ``` -Subject -: (`string`) The commit message subject. +###### Subject + +(`string`) The commit message subject. ```go-html-template {{ with .GitInfo }} diff --git a/content/en/methods/page/Next.md b/content/en/methods/page/Next.md index 3c9e3495a..57fc1f2f8 100644 --- a/content/en/methods/page/Next.md +++ b/content/en/methods/page/Next.md @@ -10,7 +10,7 @@ action: - methods/page/PrevInSection - methods/pages/Next - methods/pages/Prev - returnType: hugolib.pageState + returnType: page.Page signatures: [PAGE.Next] toc: true --- diff --git a/content/en/methods/page/NextInSection.md b/content/en/methods/page/NextInSection.md index b48ddcc62..73f82d754 100644 --- a/content/en/methods/page/NextInSection.md +++ b/content/en/methods/page/NextInSection.md @@ -10,7 +10,7 @@ action: - methods/page/Prev - methods/pages/Next - methods/pages/Prev - returnType: hugolib.pageState + returnType: page.Page signatures: [PAGE.NextInSection] --- diff --git a/content/en/methods/page/Page.md b/content/en/methods/page/Page.md index 2c0536bee..4d81c04ef 100644 --- a/content/en/methods/page/Page.md +++ b/content/en/methods/page/Page.md @@ -5,7 +5,7 @@ categories: [] keywords: [] action: related: [] - returnType: hugolib.pageState + returnType: page.Page signatures: [PAGE.Page] --- diff --git a/content/en/methods/page/Params.md b/content/en/methods/page/Params.md index ce624c394..3d79d15c5 100644 --- a/content/en/methods/page/Params.md +++ b/content/en/methods/page/Params.md @@ -18,7 +18,6 @@ With this front matter: title = 'Annual conference' date = 2023-10-17T15:11:37-07:00 display_related = true -event-date = '2023' [params.author] email = 'jsmith@example.org' name = 'John Smith' @@ -36,8 +35,9 @@ Access the custom parameters by [chaining] the [identifiers]: In the template example above, each of the keys is a valid identifier. For example, none of the keys contains a hyphen. To access a key that is not a valid identifier, use the [`index`] function: ```go-html-template -{{ index .Params "event-date" }} → 2023 +{{ index .Params "key-with-hyphens" }} → 2023 ``` + [`index`]: /functions/collections/indexfunction [chaining]: /getting-started/glossary/#chain [identifiers]: /getting-started/glossary/#identifier diff --git a/content/en/methods/page/Parent.md b/content/en/methods/page/Parent.md index dbd2cb9b3..9d9ed7ea3 100644 --- a/content/en/methods/page/Parent.md +++ b/content/en/methods/page/Parent.md @@ -12,7 +12,7 @@ action: - methods/page/IsAncestor - methods/page/IsDescendant - methods/page/Sections - returnType: hugolib.pageState + returnType: page.Page signatures: [PAGE.Parent] --- diff --git a/content/en/methods/page/Permalink.md b/content/en/methods/page/Permalink.md index be6df5aad..d8416df86 100644 --- a/content/en/methods/page/Permalink.md +++ b/content/en/methods/page/Permalink.md @@ -21,5 +21,5 @@ Template: ```go-html-template {{ $page := .Site.GetPage "/about" }} -{{ $page.RelPermalink }} → https://example.org/docs/about/ +{{ $page.Permalink }} → https://example.org/docs/about/ ``` diff --git a/content/en/methods/page/Prev.md b/content/en/methods/page/Prev.md index cde83b0f2..b1a503af5 100644 --- a/content/en/methods/page/Prev.md +++ b/content/en/methods/page/Prev.md @@ -10,7 +10,7 @@ action: - methods/page/NextInSection - methods/pages/Prev - methods/pages/Next - returnType: hugolib.pageState + returnType: page.Page signatures: [PAGE.Prev] toc: true --- diff --git a/content/en/methods/page/PrevInSection.md b/content/en/methods/page/PrevInSection.md index 30b813350..c09e4580f 100644 --- a/content/en/methods/page/PrevInSection.md +++ b/content/en/methods/page/PrevInSection.md @@ -10,7 +10,7 @@ action: - methods/pages/Next - methods/page/Prev - methods/pages/Prev - returnType: hugolib.pageState + returnType: page.Page signatures: [PAGE.PrevInSection] --- diff --git a/content/en/methods/page/RelPermalink.md b/content/en/methods/page/RelPermalink.md index 8a5972ccc..817e3c862 100644 --- a/content/en/methods/page/RelPermalink.md +++ b/content/en/methods/page/RelPermalink.md @@ -21,5 +21,5 @@ Template: ```go-html-template {{ $page := .Site.GetPage "/about" }} -{{ $page.Permalink }} → /docs/about/ +{{ $page.RelPermalink }} → /docs/about/ ``` diff --git a/content/en/methods/page/Resources.md b/content/en/methods/page/Resources.md index a9fa3dab2..140b50020 100644 --- a/content/en/methods/page/Resources.md +++ b/content/en/methods/page/Resources.md @@ -21,8 +21,9 @@ To work with global or remote resources, see the [`resources`] functions. ## Methods -ByType -: (`resource.Resources`) Returns a collection of page resources of the given [media type], or nil if none found. The media type is typically one of `image`, `text`, `audio`, `video`, or `application`. +###### ByType + +(`resource.Resources`) Returns a collection of page resources of the given [media type], or nil if none found. The media type is typically one of `image`, `text`, `audio`, `video`, or `application`. ```go-html-template {{ range .Resources.ByType "image" }} @@ -32,8 +33,9 @@ ByType When working with global resources instead of page resources, use the [`resources.ByType`] function. -Get -: (`resource.Resource`) Returns a page resource from the given path, or nil if none found. +###### Get + +(`resource.Resource`) Returns a page resource from the given path, or nil if none found. ```go-html-template {{ with .Resources.Get "images/a.jpg" }} @@ -43,8 +45,9 @@ Get When working with global resources instead of page resources, use the [`resources.Get`] function. -GetMatch -: (`resource.Resource`) Returns the first page resource from paths matching the given [glob pattern], or nil if none found. +###### GetMatch + +(`resource.Resource`) Returns the first page resource from paths matching the given [glob pattern], or nil if none found. ```go-html-template {{ with .Resources.GetMatch "images/*.jpg" }} @@ -54,8 +57,9 @@ GetMatch When working with global resources instead of page resources, use the [`resources.GetMatch`] function. -Match -: (`resource.Resources`) Returns a collection of page resources from paths matching the given [glob pattern], or nil if none found. +###### Match + +(`resource.Resources`) Returns a collection of page resources from paths matching the given [glob pattern], or nil if none found. ```go-html-template {{ range .Resources.Match "images/*.jpg" }} diff --git a/content/en/methods/page/Store.md b/content/en/methods/page/Store.md index 04e1d5256..8bc16034b 100644 --- a/content/en/methods/page/Store.md +++ b/content/en/methods/page/Store.md @@ -22,25 +22,28 @@ To create a locally scoped scratch pad that is not attached to a `Page` object, ## Methods -Set -: Sets the value of a given key. +###### Set + +Sets the value of a given key. ```go-html-template {{ .Store.Set "greeting" "Hello" }} ``` -Get -: Gets the value of a given key. +###### Get + +Gets the value of a given key. ```go-html-template {{ .Store.Set "greeting" "Hello" }} {{ .Store.Get "greeting" }} → Hello ``` -Add -: Adds a given value to existing value(s) of the given key. +###### Add -: For single values, `Add` accepts values that support Go's `+` operator. If the first `Add` for a key is an array or slice, the following adds will be appended to that list. +Adds a given value to existing value(s) of the given key. + +For single values, `Add` accepts values that support Go's `+` operator. If the first `Add` for a key is an array or slice, the following adds will be appended to that list. ```go-html-template {{ .Store.Set "greeting" "Hello" }} @@ -60,8 +63,9 @@ Add {{ .Store.Get "greetings" }} → [Hello Welcome Cheers] ``` -SetInMap -: Takes a `key`, `mapKey` and `value` and adds a map of `mapKey` and `value` to the given `key`. +###### SetInMap + +Takes a `key`, `mapKey` and `value` and adds a map of `mapKey` and `value` to the given `key`. ```go-html-template {{ .Store.SetInMap "greetings" "english" "Hello" }} @@ -69,8 +73,9 @@ SetInMap {{ .Store.Get "greetings" }} → map[english:Hello french:Bonjour] ``` -DeleteInMap -: Takes a `key` and `mapKey` and removes the map of `mapKey` from the given `key`. +###### DeleteInMap + +Takes a `key` and `mapKey` and removes the map of `mapKey` from the given `key`. ```go-html-template {{ .Store.SetInMap "greetings" "english" "Hello" }} @@ -79,8 +84,9 @@ DeleteInMap {{ .Store.Get "greetings" }} → map[french:Bonjour] ``` -GetSortedMapValues -: Returns an array of values from `key` sorted by `mapKey`. +###### GetSortedMapValues + +Returns an array of values from `key` sorted by `mapKey`. ```go-html-template {{ .Store.SetInMap "greetings" "english" "Hello" }} @@ -88,8 +94,9 @@ GetSortedMapValues {{ .Store.GetSortedMapValues "greetings" }} → [Hello Bonjour] ``` -Delete -: Removes the given key. +###### Delete + +Removes the given key. ```go-html-template {{ .Store.Set "greeting" "Hello" }} diff --git a/content/en/methods/page/Translations.md b/content/en/methods/page/Translations.md index 7aaee75ab..1ed256630 100644 --- a/content/en/methods/page/Translations.md +++ b/content/en/methods/page/Translations.md @@ -63,8 +63,9 @@ And this template: {{ with .Translations }} {{ end }} @@ -74,8 +75,8 @@ Hugo will render this list on the "Book 1" page of the English site: ```html ``` @@ -83,6 +84,6 @@ Hugo will render this list on the "Book 2" page of the English site: ```html ``` diff --git a/content/en/methods/page/_common/scratch-methods.md b/content/en/methods/page/_common/scratch-methods.md index c09b4aadc..b2650cdde 100644 --- a/content/en/methods/page/_common/scratch-methods.md +++ b/content/en/methods/page/_common/scratch-methods.md @@ -4,25 +4,28 @@ ## Methods -Set -: Sets the value of a given key. +###### Set + +Sets the value of a given key. ```go-html-template {{ .Scratch.Set "greeting" "Hello" }} ``` -Get -: Gets the value of a given key. +###### Get + +Gets the value of a given key. ```go-html-template {{ .Scratch.Set "greeting" "Hello" }} {{ .Scratch.Get "greeting" }} → Hello ``` -Add -: Adds a given value to existing value(s) of the given key. +###### Add -: For single values, `Add` accepts values that support Go's `+` operator. If the first `Add` for a key is an array or slice, the following adds will be appended to that list. +Adds a given value to existing value(s) of the given key. + +For single values, `Add` accepts values that support Go's `+` operator. If the first `Add` for a key is an array or slice, the following adds will be appended to that list. ```go-html-template {{ .Scratch.Set "greeting" "Hello" }} @@ -42,8 +45,9 @@ Add {{ .Scratch.Get "greetings" }} → [Hello Welcome Cheers] ``` -SetInMap -: Takes a `key`, `mapKey` and `value` and adds a map of `mapKey` and `value` to the given `key`. +###### SetInMap + +Takes a `key`, `mapKey` and `value` and adds a map of `mapKey` and `value` to the given `key`. ```go-html-template {{ .Scratch.SetInMap "greetings" "english" "Hello" }} @@ -51,8 +55,9 @@ SetInMap {{ .Scratch.Get "greetings" }} → map[english:Hello french:Bonjour] ``` -DeleteInMap -: Takes a `key` and `mapKey` and removes the map of `mapKey` from the given `key`. +###### DeleteInMap + +Takes a `key` and `mapKey` and removes the map of `mapKey` from the given `key`. ```go-html-template {{ .Scratch.SetInMap "greetings" "english" "Hello" }} @@ -61,8 +66,9 @@ DeleteInMap {{ .Scratch.Get "greetings" }} → map[french:Bonjour] ``` -GetSortedMapValues -: Returns an array of values from `key` sorted by `mapKey`. +###### GetSortedMapValues + +Returns an array of values from `key` sorted by `mapKey`. ```go-html-template {{ .Scratch.SetInMap "greetings" "english" "Hello" }} @@ -70,8 +76,9 @@ GetSortedMapValues {{ .Scratch.GetSortedMapValues "greetings" }} → [Hello Bonjour] ``` -Delete -: Removes the given key. +###### Delete + +Removes the given key. ```go-html-template {{ .Scratch.Set "greeting" "Hello" }} diff --git a/content/en/methods/pages/Next.md b/content/en/methods/pages/Next.md index 638822e5d..b7284609f 100644 --- a/content/en/methods/pages/Next.md +++ b/content/en/methods/pages/Next.md @@ -10,7 +10,7 @@ action: - methods/page/NextInSection - methods/page/Prev - methods/page/PrevInSection - returnType: hugolib.pageState + returnType: page.Page signatures: [PAGES.Next PAGE] toc: true --- diff --git a/content/en/methods/pages/Prev.md b/content/en/methods/pages/Prev.md index 3a4dcfd1d..b9ef27a45 100644 --- a/content/en/methods/pages/Prev.md +++ b/content/en/methods/pages/Prev.md @@ -10,7 +10,7 @@ action: - methods/page/NextInSection - methods/page/Prev - methods/page/PrevInSection - returnType: hugolib.pageStates + returnType: page.Pages signatures: [PAGES.Prev PAGE] toc: true --- diff --git a/content/en/methods/resource/Exif.md b/content/en/methods/resource/Exif.md index 75071153a..765b4c92f 100644 --- a/content/en/methods/resource/Exif.md +++ b/content/en/methods/resource/Exif.md @@ -1,6 +1,6 @@ --- title: Exif -description: Applicable to images, returns an EXIF object containing image metadata. +description: Applicable to JPEG and TIFF images, returns an EXIF object containing image metadata. categories: [] keywords: [] action: @@ -10,7 +10,7 @@ action: toc: true --- -Applicable to images, the `Exif` method on an image `Resource` object returns an [EXIF] object containing image metadata. +Applicable to JPEG and TIFF images, the `Exif` method on an image `Resource` object returns an [EXIF] object containing image metadata. ## Methods diff --git a/content/en/methods/shortcode/Page.md b/content/en/methods/shortcode/Page.md index c9262ab48..8bb58fa18 100644 --- a/content/en/methods/shortcode/Page.md +++ b/content/en/methods/shortcode/Page.md @@ -14,7 +14,7 @@ With this content: {{< code-toggle file=content/books/les-miserables.md fm=true >}} title = 'Les Misérables' author = 'Victor Hugo' -published = 1862 +publication_year = 1862 isbn = '978-0451419439' {{< /code-toggle >}} diff --git a/content/en/methods/site/DisqusShortname.md b/content/en/methods/site/DisqusShortname.md index 359b836af..2d4447485 100644 --- a/content/en/methods/site/DisqusShortname.md +++ b/content/en/methods/site/DisqusShortname.md @@ -7,10 +7,7 @@ action: related: [] returnType: string signatures: [SITE.DisqusShortname] -# deprecated 2023-10-30 -expiryDate: 2024-10-30 -_build: - list: never +expiryDate: 2024-10-30 # deprecated 2023-10-30 --- {{% deprecated-in 0.120.0 %}} diff --git a/content/en/methods/site/GetPage.md b/content/en/methods/site/GetPage.md index 1e949f37c..b7d4b8f32 100644 --- a/content/en/methods/site/GetPage.md +++ b/content/en/methods/site/GetPage.md @@ -6,7 +6,7 @@ keywords: [] action: related: - methods/page/GetPage - returnType: hugolib.pageState + returnType: page.Page signatures: [SITE.GetPage PATH] toc: true --- diff --git a/content/en/methods/site/GoogleAnalytics.md b/content/en/methods/site/GoogleAnalytics.md index 405cf0de5..50f479b49 100644 --- a/content/en/methods/site/GoogleAnalytics.md +++ b/content/en/methods/site/GoogleAnalytics.md @@ -7,10 +7,7 @@ action: related: [] returnType: string signatures: [SITE.GoogleAnalytics] -# deprecated 2023-10-30 -expiryDate: 2024-10-30 -_build: - list: never +expiryDate: 2024-10-30 # deprecated 2023-10-30 --- {{% deprecated-in 0.120.0 %}} diff --git a/content/en/methods/site/Home.md b/content/en/methods/site/Home.md index 52612dd12..a25491a8e 100644 --- a/content/en/methods/site/Home.md +++ b/content/en/methods/site/Home.md @@ -5,7 +5,7 @@ categories: [] keywords: [] action: related: [] - returnType: hugolib.pageState + returnType: page.Page signatures: [SITE.Home] --- diff --git a/content/en/methods/site/IsDevelopment.md b/content/en/methods/site/IsDevelopment.md index fdeae15fa..c009ba0de 100644 --- a/content/en/methods/site/IsDevelopment.md +++ b/content/en/methods/site/IsDevelopment.md @@ -7,10 +7,7 @@ action: related: [] returnType: bool signatures: [SITE.IsDevelopment] -# deprecated 2023-10-30 -expiryDate: 2024-10-30 -_build: - list: never +expiryDate: 2024-10-30 # deprecated 2023-10-30 --- {{% deprecated-in 0.120.0 %}} @@ -18,3 +15,7 @@ Use [`hugo.IsDevelopment`] instead. [`hugo.IsDevelopment`]: /functions/hugo/isdevelopment {{% /deprecated-in %}} + +```go-html-template +{{ .Site.IsDevelopment }} → true/false +``` diff --git a/content/en/methods/site/IsServer.md b/content/en/methods/site/IsServer.md index c19a84bc9..3d5ce41b5 100644 --- a/content/en/methods/site/IsServer.md +++ b/content/en/methods/site/IsServer.md @@ -7,10 +7,7 @@ action: related: [] returnType: bool signatures: [SITE.IsServer] -# deprecated 2023-10-30 -expiryDate: 2024-10-30 -_build: - list: never +expiryDate: 2024-10-30 # deprecated 2023-10-30 --- {{% deprecated-in 0.120.0 %}} @@ -18,3 +15,7 @@ Use [`hugo.IsServer`] instead. [`hugo.IsServer`]: /functions/hugo/isserver {{% /deprecated-in %}} + +```go-html-template +{{ .Site.IsServer }} → true/false +``` diff --git a/content/en/methods/site/Menus.md b/content/en/methods/site/Menus.md index 1967a9211..c204fe97b 100644 --- a/content/en/methods/site/Menus.md +++ b/content/en/methods/site/Menus.md @@ -22,27 +22,27 @@ Menus can be defined and localized in several ways. Please see the [menus] secti A site can have multiple menus. For example, a main menu and a footer menu: {{< code-toggle file=hugo >}} -[[menu.main]] +[[menus.main]] name = 'Home' pageRef = '/' weight = 10 -[[menu.main]] +[[menus.main]] name = 'Books' pageRef = '/books' weight = 20 -[[menu.main]] +[[menus.main]] name = 'Films' pageRef = '/films' weight = 30 -[[menu.footer]] +[[menus.footer]] name = 'Legal' pageRef = '/legal' weight = 10 -[[menu.footer]] +[[menus.footer]] name = 'Privacy' pageRef = '/privacy' weight = 20 diff --git a/content/en/methods/taxonomy/_common/ordered-taxonomy-element-methods.md b/content/en/methods/taxonomy/_common/ordered-taxonomy-element-methods.md index 57c9e8e29..9c94729ba 100644 --- a/content/en/methods/taxonomy/_common/ordered-taxonomy-element-methods.md +++ b/content/en/methods/taxonomy/_common/ordered-taxonomy-element-methods.md @@ -10,7 +10,7 @@ Count : (`int`) Returns the number of pages to which the term is assigned. Page -: (`hugolib.pageState`) Returns the term's `Page` object, useful for linking to the term page. +: (`page.Page`) Returns the term's `Page` object, useful for linking to the term page. Pages : (`page.Pages`) Returns a `Pages` object containing the `Page` objects to which the term is assigned, sorted by [taxonomic weight]. To sort or group, use any of the [methods] available to the `Pages` object. For example, sort by the last modification date. diff --git a/content/en/showcase/digitalgov/index.md b/content/en/showcase/digitalgov/index.md index 4376bbf03..3db2c608f 100644 --- a/content/en/showcase/digitalgov/index.md +++ b/content/en/showcase/digitalgov/index.md @@ -55,7 +55,7 @@ In addition to Hugo, we are proudly using a number of other tools and services, - [Federalist](https://federalist.18f.gov/) - [Search.gov](https://www.search.gov/) — A free, hosted search platform for federal websites. - [Cloud.gov](https://www.cloud.gov/) — helps teams build, run, and authorize cloud-ready or legacy government systems quickly and cheaply. -- [Federal CrowdSource Mobile Testing Program](https://digital.gov/services/mobile-application-testing-program/) — Free mobile compatibility testing by feds, for feds. +- [Federal CrowdSource Mobile Testing Program](https://digital.gov/services/service_mobile-testing-program/) — Free mobile compatibility testing by feds, for feds. - [Digital Analytics Program](https://digital.gov/services/dap/) (DAP) — A free analytics tool for measuring digital services in the federal government - [Section508.gov](https://www.section508.gov/) and [PlainLanguage.gov](https://www.plainlanguage.gov/) resources - [API.data.gov](https://api.data.gov/) — a free API management service for federal agencies diff --git a/content/en/templates/internal.md b/content/en/templates/internal.md index 2e73455f0..cc7fe155e 100644 --- a/content/en/templates/internal.md +++ b/content/en/templates/internal.md @@ -25,6 +25,7 @@ Hugo ships with an internal template supporting [Google Analytics 4]. Provide your tracking ID in your configuration file: +**Google Analytics 4 (gtag.js)** {{< code-toggle file=hugo >}} [services.googleAnalytics] ID = "G-MEASUREMENT_ID" diff --git a/content/en/templates/lookup-order.md b/content/en/templates/lookup-order.md index 2a24c03ac..406a17c38 100644 --- a/content/en/templates/lookup-order.md +++ b/content/en/templates/lookup-order.md @@ -22,7 +22,7 @@ Layout : Can be set in front matter. Output Format -: See [Custom Output Formats](/templates/output-formats). An output format has both a `name` (e.g. `rss`, `amp`, `html`) and a `suffix` (e.g. `xml`, `html`). We prefer matches with both (e.g. `index.amp.html`, but look for less specific templates. +: See [Custom Output Formats](/templates/output-formats). An output format has both a `name` (e.g. `rss`, `amp`, `html`) and a `suffix` (e.g. `xml`, `html`). We prefer matches with both (e.g. `index.amp.html`), but look for less specific templates. Note that if the output format's Media Type has more than one suffix defined, only the first is considered. diff --git a/content/en/templates/shortcode-templates.md b/content/en/templates/shortcode-templates.md index 4606369b6..6e3d968cf 100644 --- a/content/en/templates/shortcode-templates.md +++ b/content/en/templates/shortcode-templates.md @@ -155,7 +155,7 @@ While you can create shortcode templates that accept both positional and named p You can also use the variable `.Page` to access all the normal [page variables][pagevars]. -A shortcodes can also be nested. In a nested shortcode, you can access the parent shortcode context with [`.Parent` variable][shortcodesvars]. This can be very useful for inheritance of common shortcode parameters from the root. +Shortcodes can also be nested. In a nested shortcode, you can access the parent shortcode context with the [`.Parent`] shortcode method. This can be very useful for inheritance of common shortcode parameters from the root. ### Checking for existence @@ -307,7 +307,7 @@ The rendered output of the HTML example code block will be as follows: ### Nested shortcode: image gallery -Hugo's [`.Parent` shortcode variable][parent] provides access to the parent shortcode context when the shortcode in question is called within the context of a *parent* shortcode. This provides an inheritance model for common shortcode parameters. +Hugo's [`.Parent`] shortcode method provides access to the parent shortcode context when the shortcode in question is called within the context of a *parent* shortcode. This provides an inheritance model for common shortcode parameters. The following example is contrived but demonstrates the concept. Assume you have a `gallery` shortcode that expects one named `class` parameter: @@ -350,7 +350,7 @@ This will output the following HTML. Note how the first two `img` shortcodes inh ## Error handling in shortcodes -Use the [errorf](/functions/fmt/errorf) template func and [.Position](/variables/shortcode/) variable to get useful error messages in shortcodes: +Use the [errorf](/functions/fmt/errorf) template function and [`.Position`] shortcode method to get useful error messages in shortcodes: ```sh {{ with .Get "name" }} @@ -372,6 +372,7 @@ You can also implement your shortcodes inline -- e.g. where you use them in the This feature is disabled by default, but can be enabled in your site configuration: {{< code-toggle file=hugo >}} +[security] enableInlineShortcodes = true {{< /code-toggle >}} @@ -405,8 +406,8 @@ The same inline shortcode can be reused later in the same content file, with dif [hugosc]: /content-management/shortcodes/#using-hugo-s-built-in-shortcodes [lookup order]: /templates/lookup-order/ [pagevars]: /variables/page/ -[parent]: /variables/shortcode/ -[shortcodesvars]: /variables/shortcode/ +[`.Parent`]: /methods/shortcode/parent/ +[`.Position`]: /methods/shortcode/position/ [spfscs]: https://github.com/spf13/spf13.com/tree/master/layouts/shortcodes [vimeoexample]: #single-flexible-example-vimeo [youtubeshortcode]: /content-management/shortcodes/#youtube diff --git a/content/en/tools/search.md b/content/en/tools/search.md index 041174118..c3db0dc98 100644 --- a/content/en/tools/search.md +++ b/content/en/tools/search.md @@ -29,7 +29,7 @@ A static website with a dynamic search function? Yes, Hugo provides an alternati : A bit like Hugo-lunr, but Hugo-lunr-zh can help you separate the Chinese keywords. [GitHub Gist for Fuse.js integration](https://gist.github.com/eddiewebb/735feb48f50f0ddd65ae5606a1cb41ae) -: This gist demonstrates how to leverage Hugo's existing build time processing to generate a searchable JSON index used by [Fuse.js](https://fusejs.io/) on the client-side. Although this gist uses Fuse.js for fuzzy matching, any client-side search tool capable of reading JSON indexes will work. Does not require npm, grunt or other build-time tools except Hugo! +: This gist demonstrates how to leverage Hugo's existing build time processing to generate a searchable JSON index used by [Fuse.js](https://fusejs.io/) on the client-side. Although this gist uses Fuse.js for fuzzy matching, any client-side search tool capable of reading JSON indexes will work. Does not require npm, grunt, or other build-time tools except Hugo! [hugo-search-index](https://www.npmjs.com/package/hugo-search-index) : A library containing Gulp tasks and a prebuilt browser script that implements search. Gulp generates a search index from project markdown files. @@ -49,7 +49,7 @@ A static website with a dynamic search function? Yes, Hugo provides an alternati : Algolia's Search API makes it easy to deliver a great search experience in your apps and websites. Algolia Search provides hosted full-text, numerical, faceted, and geolocalized search. [Bonsai](https://www.bonsai.io) -: Bonsai is a fully-managed hosted Elasticsearch service that is fast, reliable, and simple to set up. Easily ingest your docs from Hugo into Elasticsearch following [this guide from the docs](https://docs.bonsai.io/hc/en-us/articles/13929190788756-Hugo). +: Bonsai is a fully-managed hosted Elasticsearch service that is fast, reliable, and simple to set up. Easily ingest your docs from Hugo into Elasticsearch following [this guide from the docs](https://bonsai.io/docs/hugo). [ExpertRec](https://www.expertrec.com/) : ExpertRec is a hosted search-as-a-service solution that is fast and scalable. Set-up and integration is extremely easy and takes only a few minutes. The search settings can be modified without coding using a dashboard. diff --git a/content/en/troubleshooting/deprecation.md b/content/en/troubleshooting/deprecation.md index 9aef54e8a..aa4bb71a2 100644 --- a/content/en/troubleshooting/deprecation.md +++ b/content/en/troubleshooting/deprecation.md @@ -16,13 +16,13 @@ When a project _deprecates_ something, they are telling its users: 2. Use Thing Two instead. 3. We're going to remove Thing One at some point in the future. -[article]: https://en.wikipedia.org/wiki/Deprecation +[reasons for deprecation]: https://en.wikipedia.org/wiki/Deprecation -Think of deprecation as a statement of intent. This Wikipedia [article] describes common reasons for deprecation: +Common [reasons for deprecation]: -- The feature has been replaced by a more powerful alternative. -- The feature contains a design flaw. -- The feature is considered extraneous, and will be removed in the future in order to simplify the system as a whole. +- A feature has been replaced by a more powerful alternative. +- A feature contains a design flaw. +- A feature is considered extraneous, and will be removed in the future in order to simplify the system as a whole. - A future version of the software will make major structural changes, making it impossible or impractical to support older features. - Standardization or increased consistency in naming. - A feature that once was available only independently is now combined with its co-feature. diff --git a/content/en/troubleshooting/faq.md b/content/en/troubleshooting/faq.md index dc6204777..0425ca277 100644 --- a/content/en/troubleshooting/faq.md +++ b/content/en/troubleshooting/faq.md @@ -107,7 +107,7 @@ The most common causes are page collisions (publishing two pages to the same pat ###### Which page methods trigger content rendering? -The following methods on a `Page` object triggering content rendering: `Content`, `FuzzyWordCount`, `Len`, `Plain`, `PlainWords`, `ReadingTime`, `Summary`, `Truncated`, and `WordCount`. +The following methods on a `Page` object trigger content rendering: `Content`, `FuzzyWordCount`, `Len`, `Plain`, `PlainWords`, `ReadingTime`, `Summary`, `Truncated`, and `WordCount`. {{% note %}} For other questions please visit the [forum]. A quick search of over 20,000 topics will often answer your question. Please be sure to read about [requesting help] before asking your first question. diff --git a/content/en/troubleshooting/performance.md b/content/en/troubleshooting/performance.md index 589d30df6..174d6cfd9 100644 --- a/content/en/troubleshooting/performance.md +++ b/content/en/troubleshooting/performance.md @@ -14,7 +14,7 @@ aliases: [/troubleshooting/build-performance/] ## Template metrics -Hugo is fast, but inefficient templates impede performance. Enable template metrics to determine which templates take the most time, and to identify caching opportunties: +Hugo is fast, but inefficient templates impede performance. Enable template metrics to determine which templates take the most time, and to identify caching opportunities: ```sh hugo --templateMetrics --templateMetricsHints diff --git a/data/docs.yaml b/data/docs.yaml index 2cdb0dd53..f59974724 100644 --- a/data/docs.yaml +++ b/data/docs.yaml @@ -19,9 +19,15 @@ chroma: - ada95 - ada2005 Name: Ada + - Aliases: + - agda + Name: Agda - Aliases: - al Name: AL + - Aliases: + - alloy + Name: Alloy - Aliases: - ng2 Name: Angular2 @@ -198,6 +204,9 @@ chroma: - Aliases: - dart Name: Dart + - Aliases: + - dax + Name: Dax - Aliases: - diff - udiff @@ -330,6 +339,9 @@ chroma: - handlebars - hbs Name: Handlebars + - Aliases: + - hare + Name: Hare - Aliases: - haskell - hs @@ -501,6 +513,9 @@ chroma: - obj-c - objc Name: Objective-C + - Aliases: + - objectpascal + Name: ObjectPascal - Aliases: - ocaml Name: OCaml @@ -824,6 +839,8 @@ chroma: - Aliases: - typoscripthtmldata Name: TypoScriptHtmlData + - Aliases: null + Name: ucode - Aliases: - v - vlang @@ -1254,6 +1271,9 @@ config: keepEndTags: true keepQuotes: false keepWhitespace: false + templateDelims: + - "" + - "" js: keepVarNames: false precision: 0 @@ -1563,8 +1583,6 @@ config: getenv: - ^HUGO_ - ^CI$ - goTemplates: - allowActionJSTmpl: false http: mediaTypes: null methods: @@ -2741,6 +2759,21 @@ tpl: map[string]interface {}{ "Hugo": "Rocks!", } + TestDeprecationErr: + Aliases: null + Args: null + Description: "" + Examples: null + TestDeprecationInfo: + Aliases: null + Args: null + Description: "" + Examples: null + TestDeprecationWarn: + Aliases: null + Args: null + Description: "" + Examples: null Timer: Aliases: null Args: null @@ -4364,6 +4397,16 @@ tpl: - - '{{ "hello = \"Hello World\"" | resources.FromString "data/greetings.toml" | transform.Unmarshal }}' - map[hello:Hello World] + XMLEscape: + Aliases: null + Args: + - s + Description: |- + XMLEscape returns the given string, removing disallowed characters then + escaping the result to its XML equivalent. + Examples: + - - '{{ transform.XMLEscape "

abc

" }}' + - '<p>abc</p>' urls: AbsLangURL: Aliases: diff --git a/go.mod b/go.mod index b53b245e1..ac58db6b3 100644 --- a/go.mod +++ b/go.mod @@ -2,4 +2,4 @@ module github.com/gohugoio/hugoDocs go 1.16 -require github.com/gohugoio/gohugoioTheme v0.0.0-20231111235806-77931ac4875e // indirect +require github.com/gohugoio/gohugoioTheme v0.0.0-20240125093153-bea12fdc0b15 // indirect diff --git a/go.sum b/go.sum index d8cea868c..3d66fb551 100644 --- a/go.sum +++ b/go.sum @@ -1,2 +1,4 @@ -github.com/gohugoio/gohugoioTheme v0.0.0-20231111235806-77931ac4875e h1:X4OxWNt7weGfmRHBAQWW1gsdZBd3V/6DJMNhrYS9ALE= -github.com/gohugoio/gohugoioTheme v0.0.0-20231111235806-77931ac4875e/go.mod h1:GOYeAPQJ/ok8z7oz1cjfcSlsFpXrmx6VkzQ5RpnyhZM= +github.com/gohugoio/gohugoioTheme v0.0.0-20240108005931-638ffe386bd2 h1:wa2rkKQnFxJK0czyiCiKgJZZ9fQQlzn1iFsuKryffHE= +github.com/gohugoio/gohugoioTheme v0.0.0-20240108005931-638ffe386bd2/go.mod h1:GOYeAPQJ/ok8z7oz1cjfcSlsFpXrmx6VkzQ5RpnyhZM= +github.com/gohugoio/gohugoioTheme v0.0.0-20240125093153-bea12fdc0b15 h1:NJvuWADEYyNmpyRScXC/1dIwy6kqLDkwB9GP3Wq4W+I= +github.com/gohugoio/gohugoioTheme v0.0.0-20240125093153-bea12fdc0b15/go.mod h1:GOYeAPQJ/ok8z7oz1cjfcSlsFpXrmx6VkzQ5RpnyhZM= diff --git a/hugo.toml b/hugo.toml index 026743466..209231663 100644 --- a/hugo.toml +++ b/hugo.toml @@ -93,3 +93,8 @@ ID = 'G-MBZGKNMDWC' [taxonomies] category = "categories" + +[[cascade]] +categories = ['commands'] +[cascade._target] +path = '/commands/**' diff --git a/layouts/shortcodes/new-in.html b/layouts/shortcodes/new-in.html deleted file mode 100644 index e22a91f3d..000000000 --- a/layouts/shortcodes/new-in.html +++ /dev/null @@ -1,36 +0,0 @@ -{{- /* -Renders a "new in" button indicating the version in which a feature was added. - -When comparing the current version to the specified version, the "new in" -button will be hidden if any of the following conditions is true: - -- The major version difference exceeds the majorVersionDiffThreshold -- The minor version difference exceeds the minorVersionDiffThreshold - -@param {string} version The semantic version string, with or without a leading v. -@returns {template.HTML} - -@example {{< new-in 0.100.0 >}} -*/}} - -{{- /* Set defaults. */}} -{{- $majorVersionDiffThreshold := 0 }} -{{- $minorVersionDiffThreshold := 30 }} -{{- $displayExpirationWarning := true }} - -{{- /* Render. */}} -{{- with $version := .Get 0 | strings.TrimPrefix "v" }} - {{- $majorVersionDiff := sub (index (split hugo.Version ".") 0 | int) (index (split $version ".") 0 | int) }} - {{- $minorVersionDiff := sub (index (split hugo.Version ".") 1 | int) (index (split $version ".") 1 | int) }} - {{- if or (gt $majorVersionDiff $majorVersionDiffThreshold) (gt $minorVersionDiff $minorVersionDiffThreshold) }} - {{- if $displayExpirationWarning }} - {{- warnf "This call to the %q shortcode should be removed: %s. The button is now hidden because the specified version (%s) is older than the display threshold." $.Name $.Position $version }} - {{- end }} - {{- else }} - - {{- end }} -{{- else }} - {{- errorf "The %q shortcode requires a positional parameter (version). See %s" .Name .Position }} -{{- end -}} diff --git a/netlify.toml b/netlify.toml index cc46695a5..7c5633da8 100644 --- a/netlify.toml +++ b/netlify.toml @@ -3,7 +3,7 @@ command = "hugo --gc --minify" [build.environment] - HUGO_VERSION = "0.120.4" + HUGO_VERSION = "0.121.2" [context.production.environment] HUGO_ENV = "production"