From 77f4d6c32ffc1b54dad7236166293955a9167535 Mon Sep 17 00:00:00 2001 From: Joe Mooring Date: Sat, 25 Mar 2023 20:48:48 -0700 Subject: [PATCH] Link destination cleanup (#2028) - Fix broken links (including fragments) - Remove ref and relref shortcodes --- .../en/content-management/build-options.md | 6 +- .../image-processing/index.md | 14 ++--- content/en/content-management/multilingual.md | 10 +-- .../content-management/organization/index.md | 2 +- .../en/content-management/page-resources.md | 3 +- content/en/content-management/taxonomies.md | 4 +- content/en/functions/fileExists.md | 2 +- content/en/functions/highlight.md | 8 +-- content/en/functions/int.md | 3 +- content/en/functions/lang.md | 2 - content/en/functions/merge.md | 2 +- content/en/functions/os.Stat.md | 2 +- content/en/functions/readdir.md | 2 +- content/en/functions/readfile.md | 4 +- content/en/functions/site.md | 2 +- content/en/functions/split.md | 2 +- content/en/functions/where.md | 2 +- content/en/getting-started/configuration.md | 4 +- .../en/getting-started/directory-structure.md | 2 +- .../hosting-on-netlify.md | 3 +- content/en/hugo-pipes/transform-to-css.md | 2 +- content/en/news/0.11-relnotes/index.md | 12 ++-- content/en/news/0.12-relnotes/index.md | 10 +-- content/en/news/0.14-relnotes/index.md | 2 +- content/en/news/0.20-relnotes/index.md | 62 +++++++++---------- content/en/news/0.20.1-relnotes/index.md | 8 +-- content/en/news/0.20.2-relnotes/index.md | 4 +- content/en/news/0.63.0-relnotes/index.md | 7 --- .../index.md | 2 +- content/en/templates/data-templates.md | 5 +- content/en/templates/introduction.md | 35 +++++------ .../en/templates/{lists.md => lists/index.md} | 2 +- .../en/templates/lists}/site-hierarchy.svg | 0 content/en/templates/output-formats.md | 2 +- content/en/templates/partials.md | 12 ++-- content/en/templates/sitemap-template.md | 2 +- content/en/templates/taxonomy-templates.md | 8 +-- .../en/troubleshooting/build-performance.md | 2 +- content/en/variables/page.md | 6 +- content/en/variables/site.md | 4 +- 40 files changed, 126 insertions(+), 140 deletions(-) rename content/en/templates/{lists.md => lists/index.md} (99%) rename {static/images => content/en/templates/lists}/site-hierarchy.svg (100%) diff --git a/content/en/content-management/build-options.md b/content/en/content-management/build-options.md index f798754f1..07187e718 100644 --- a/content/en/content-management/build-options.md +++ b/content/en/content-management/build-options.md @@ -56,11 +56,11 @@ If true, the page will be treated as part of the project's collections and, when #### publishResources -If set to true the [Bundle's Resources]({{< relref "content-management/page-bundles" >}}) will be published. +If set to true the [Bundle's Resources](/content-management/page-bundles) will be published. Setting this to false will still publish Resources on demand (when a resource's `.Permalink` or `.RelPermalink` is invoked from the templates) but will skip the others. {{% note %}} -Any page, regardless of their build options, will always be available using the [`.GetPage`]({{< relref "functions/GetPage" >}}) methods. +Any page, regardless of their build options, will always be available using the [`.GetPage`](/functions/GetPage) methods. {{% /note %}} ------ @@ -92,7 +92,7 @@ _build: Website needs to showcase a few of the hundred "testimonials" available as content files without publishing any of them. -To avoid setting the build options on every testimonials, one can use [`cascade`]({{< relref "/content-management/front-matter#front-matter-cascade" >}}) on the testimonial section's content file. +To avoid setting the build options on every testimonials, one can use [`cascade`](/content-management/front-matter#front-matter-cascade) on the testimonial section's content file. {{< code-toggle >}} title: Testimonials diff --git a/content/en/content-management/image-processing/index.md b/content/en/content-management/image-processing/index.md index 3f71b4244..388662856 100644 --- a/content/en/content-management/image-processing/index.md +++ b/content/en/content-management/image-processing/index.md @@ -457,15 +457,15 @@ If you change image processing methods or options, or if you rename or remove im hugo --gc ``` -[`anchor`]: {{< relref "content-management/image-processing#anchor" >}} -[`lang.FormatNumber`]: {{< relref "functions/lang#langformatnumber" >}} -[Exif]: -[filters]: {{< relref "functions/images" >}} +[time.Format]: /functions/dateformat +[`anchor`]: /content-management/image-processing#anchor +[mounted]: /hugo-modules/configuration#module-config-mounts +[page bundle]: /content-management/page-bundles +[`lang.FormatNumber`]: /functions/lang +[filters]: /functions/images [github.com/disintegration/imaging]: -[mounted]: {{< relref "hugo-modules/configuration#module-config-mounts">}} -[page bundle]: {{< relref "content-management/page-bundles" >}} [Smartcrop]: -[time.Format]: {{< relref "functions/dateformat" >}} +[Exif]: [`Colors`]: #colors [`Crop`]: #crop [`Exif`]: #exif diff --git a/content/en/content-management/multilingual.md b/content/en/content-management/multilingual.md index 130d2d523..3fb5139de 100644 --- a/content/en/content-management/multilingual.md +++ b/content/en/content-management/multilingual.md @@ -607,11 +607,11 @@ hugo new content/de/post/test.md [homepage]: /templates/homepage/ [Hugo Multilingual Part 1: Content translation]: https://regisphilibert.com/blog/2018/08/hugo-multilingual-part-1-managing-content-translation/ [i18func]: /functions/i18n/ -[lang.FormatAccounting]: /functions/lang/#langformataccounting -[lang.FormatCurrency]: /functions/lang/#langformatcurrency -[lang.FormatNumber]: /functions/lang/#langformatnumber -[lang.FormatNumberCustom]: /functions/lang/#langformatnumbercustom -[lang.FormatPercent]: /functions/lang/#langformatpercent +[lang.FormatAccounting]: /functions/lang +[lang.FormatCurrency]: /functions/lang +[lang.FormatNumber]: /functions/lang +[lang.FormatNumberCustom]: /functions/lang +[lang.FormatPercent]: /functions/lang [lang.Merge]: /functions/lang.merge/ [menus]: /content-management/menus/ [OS environment]: /getting-started/configuration/#configure-with-environment-variables diff --git a/content/en/content-management/organization/index.md b/content/en/content-management/organization/index.md index 6b6d6423f..efa355ddc 100644 --- a/content/en/content-management/organization/index.md +++ b/content/en/content-management/organization/index.md @@ -17,7 +17,7 @@ aliases: [/content/sections/] Hugo `0.32` announced page-relative images and other resources packaged into `Page Bundles`. -These terms are connected, and you also need to read about [Page Resources]({{< relref "/content-management/page-resources" >}}) and [Image Processing]({{< relref "/content-management/image-processing" >}}) to get the full picture. +These terms are connected, and you also need to read about [Page Resources](/content-management/page-resources) and [Image Processing](/content-management/image-processing) to get the full picture. {{< imgproc 1-featured Resize "300x" >}} The illustration shows three bundles. Note that the home page bundle cannot contain other content pages, although other files (images etc.) are allowed. diff --git a/content/en/content-management/page-resources.md b/content/en/content-management/page-resources.md index 16c9fc0ab..9e2312a5d 100644 --- a/content/en/content-management/page-resources.md +++ b/content/en/content-management/page-resources.md @@ -11,8 +11,7 @@ menu: toc: true weight: 80 --- -Page resources are only accessible from [page bundles]({{< relref -"/content-management/page-bundles" >}}), those directories with `index.md` or +Page resources are only accessible from [page bundles](/content-management/page-bundles), those directories with `index.md` or `_index.md` files at their root. Page resources are only available to the page with which they are bundled. diff --git a/content/en/content-management/taxonomies.md b/content/en/content-management/taxonomies.md index f5960367f..85e3a4c51 100644 --- a/content/en/content-management/taxonomies.md +++ b/content/en/content-management/taxonomies.md @@ -106,7 +106,7 @@ When taxonomies are used---and [taxonomy templates] are provided---Hugo will aut ## Configure Taxonomies -Custom taxonomies other than the [defaults]({{< relref "taxonomies.md#default-taxonomies" >}}) must be defined in your [site config][config] before they can be used throughout the site. You need to provide both the plural and singular labels for each taxonomy. For example, `singular key = "plural value"` for TOML and `singular key: "plural value"` for YAML. +Custom taxonomies other than the [defaults](#default-taxonomies) must be defined in your [site config][config] before they can be used throughout the site. You need to provide both the plural and singular labels for each taxonomy. For example, `singular key = "plural value"` for TOML and `singular key: "plural value"` for YAML. ### Example: Adding a custom taxonomy named "series" @@ -130,7 +130,7 @@ If you want to have just the default `tags` taxonomy, and remove the `categories tag = "tags" {{}} -If you want to disable all taxonomies altogether, see the use of `disableKinds` in [Hugo Taxonomy Defaults]({{< relref "taxonomies.md#default-taxonomies" >}}). +If you want to disable all taxonomies altogether, see the use of `disableKinds` in [Hugo Taxonomy Defaults](#default-taxonomies). {{% note %}} You can add content and front matter to your taxonomy list and taxonomy terms pages. See [Content Organization](/content-management/organization/) for more information on how to add an `_index.md` for this purpose. diff --git a/content/en/functions/fileExists.md b/content/en/functions/fileExists.md index 2175453de..0c12d7d84 100644 --- a/content/en/functions/fileExists.md +++ b/content/en/functions/fileExists.md @@ -16,7 +16,7 @@ relatedfuncs: ['os.ReadDir','os.ReadFile','os.Stat'] deprecated: false aliases: [] --- -The `os.FileExists` function attempts to resolve the path relative to the root of your project directory. If a matching file or directory is not found, it will attempt to resolve the path relative to the [`contentDir`]({{< relref "getting-started/configuration#contentdir">}}). A leading path separator (`/`) is optional. +The `os.FileExists` function attempts to resolve the path relative to the root of your project directory. If a matching file or directory is not found, it will attempt to resolve the path relative to the [`contentDir`](/getting-started/configuration#contentdir). A leading path separator (`/`) is optional. With this directory structure: diff --git a/content/en/functions/highlight.md b/content/en/functions/highlight.md index 10b1c2d90..9edf9de3e 100644 --- a/content/en/functions/highlight.md +++ b/content/en/functions/highlight.md @@ -101,8 +101,8 @@ Instead of specifying both `lineNos` and `lineNumbersInTable`, you can use the f ``` [Chroma]: https://github.com/alecthomas/chroma -[hugo client]: {{< relref "commands/hugo_gen_chromastyles" >}} -[options]: {{< relref "#options" >}} -[site configuration]: {{< relref "getting-started/configuration-markup#highlight">}} +[hugo client]: /commands/hugo_gen_chromastyles +[options]: #options +[site configuration]: /getting-started/configuration-markup#highlight [style gallery]: https://xyproto.github.io/splash/docs/ -[supported languages]: {{< relref "content-management/syntax-highlighting#list-of-chroma-highlighting-languages" >}} +[supported languages]: /content-management/syntax-highlighting#list-of-chroma-highlighting-languages diff --git a/content/en/functions/int.md b/content/en/functions/int.md index 33888e117..309368702 100644 --- a/content/en/functions/int.md +++ b/content/en/functions/int.md @@ -30,8 +30,7 @@ leading 0's, then those 0's will have to be removed before passing the string to the `int` function, else that string will be tried to be parsed as an octal number representation. -The [`strings.TrimLeft` function](/functions/strings.trimleft/) can be used for -this purpose. +The `strings.TrimLeft` can be used for this purpose. ``` {{ int ("0987" | strings.TrimLeft "0") }} diff --git a/content/en/functions/lang.md b/content/en/functions/lang.md index 1a4da807a..db353383c 100644 --- a/content/en/functions/lang.md +++ b/content/en/functions/lang.md @@ -11,6 +11,4 @@ menu: signature: ["lang.NumFmt PRECISION NUMBER [OPTIONS [DELIMITER]]"] aliases: ['/functions/numfmt/'] type: 'template-func' - --- - diff --git a/content/en/functions/merge.md b/content/en/functions/merge.md index 0944815a1..a73644dcb 100644 --- a/content/en/functions/merge.md +++ b/content/en/functions/merge.md @@ -67,5 +67,5 @@ Example 4 ``` {{% note %}} -Regardless of depth, merging only applies to maps. For slices, use [append]({{< ref "functions/append" >}}). +Regardless of depth, merging only applies to maps. For slices, use [append](/functions/append). {{% /note %}} diff --git a/content/en/functions/os.Stat.md b/content/en/functions/os.Stat.md index a56f79735..14adc0ba1 100644 --- a/content/en/functions/os.Stat.md +++ b/content/en/functions/os.Stat.md @@ -16,7 +16,7 @@ relatedfuncs: ['os.FileExists','os.ReadDir','os.ReadFile'] deprecated: false aliases: [] --- -The `os.Stat` function attempts to resolve the path relative to the root of your project directory. If a matching file or directory is not found, it will attempt to resolve the path relative to the [`contentDir`]({{< relref "getting-started/configuration#contentdir">}}). A leading path separator (`/`) is optional. +The `os.Stat` function attempts to resolve the path relative to the root of your project directory. If a matching file or directory is not found, it will attempt to resolve the path relative to the [`contentDir`](/getting-started/configuration#contentdir). A leading path separator (`/`) is optional. ```go-html-template {{ $f := os.Stat "README.md" }} diff --git a/content/en/functions/readdir.md b/content/en/functions/readdir.md index 70fe7b66c..ef4e39e71 100644 --- a/content/en/functions/readdir.md +++ b/content/en/functions/readdir.md @@ -48,4 +48,4 @@ Note that `os.ReadDir` is not recursive. Details of the `FileInfo` structure are available in the [Go documentation](https://pkg.go.dev/io/fs#FileInfo). -For more information on using `readDir` and `readFile` in your templates, see [Local File Templates]({{< relref "/templates/files" >}}). +For more information on using `readDir` and `readFile` in your templates, see [Local File Templates](/templates/files). diff --git a/content/en/functions/readfile.md b/content/en/functions/readfile.md index b0a88458b..ab782f1df 100644 --- a/content/en/functions/readfile.md +++ b/content/en/functions/readfile.md @@ -16,7 +16,7 @@ relatedfuncs: ['os.FileExists','os.ReadDir','os.Stat'] deprecated: false aliases: [] --- -The `os.ReadFile` function attempts to resolve the path relative to the root of your project directory. If a matching file is not found, it will attempt to resolve the path relative to the [`contentDir`]({{< relref "getting-started/configuration#contentdir">}}). A leading path separator (`/`) is optional. +The `os.ReadFile` function attempts to resolve the path relative to the root of your project directory. If a matching file is not found, it will attempt to resolve the path relative to the [`contentDir`](/getting-started/configuration#contentdir). A leading path separator (`/`) is optional. With a file named README.md in the root of your project directory: @@ -38,4 +38,4 @@ This is **bold** text. Note that `os.ReadFile` returns raw (uninterpreted) content. -For more information on using `readDir` and `readFile` in your templates, see [Local File Templates]({{< relref "/templates/files" >}}). +For more information on using `readDir` and `readFile` in your templates, see [Local File Templates](/templates/files). diff --git a/content/en/functions/site.md b/content/en/functions/site.md index d4b8e417c..30b8d6505 100644 --- a/content/en/functions/site.md +++ b/content/en/functions/site.md @@ -20,4 +20,4 @@ draft: false aliases: [] --- -`site` is a global function which returns the same data as the `.Site` page method. See: [Site Variables]({{< relref "/variables/site" >}}). +`site` is a global function which returns the same data as the `.Site` page method. See: [Site Variables](/variables/site). diff --git a/content/en/functions/split.md b/content/en/functions/split.md index 51d1a64f7..8d54521b6 100644 --- a/content/en/functions/split.md +++ b/content/en/functions/split.md @@ -26,5 +26,5 @@ Examples: {{% note %}} -`split` essentially does the opposite of [delimit]({{< ref "functions/delimit" >}}). While `split` creates a slice from a string, `delimit` creates a string from a slice. +`split` essentially does the opposite of [delimit](/functions/delimit). While `split` creates a slice from a string, `delimit` creates a string from a slice. {{% /note %}} diff --git a/content/en/functions/where.md b/content/en/functions/where.md index b7d31f645..a06ee020f 100644 --- a/content/en/functions/where.md +++ b/content/en/functions/where.md @@ -115,7 +115,7 @@ You can also put the returned value of the `where` clauses into a variable: Using `first` and `where` together can be very powerful. Below snippet gets a list of posts only from [**main -sections**]({{< relref "where.md#mainsections" >}}), sorts it using the [default +sections**](#mainsections), sorts it using the [default ordering](/templates/lists/) for lists (i.e., `weight => date`), and then ranges through only the first 5 posts in that list: diff --git a/content/en/getting-started/configuration.md b/content/en/getting-started/configuration.md index 99d11fbb1..a6985edbf 100644 --- a/content/en/getting-started/configuration.md +++ b/content/en/getting-started/configuration.md @@ -321,7 +321,7 @@ See [Configure Media Types](/templates/output-formats/#media-types). ### menus -See [Add Non-content Entries to a Menu](/content-management/menus/#add-non-content-entries-to-a-menu). +See [Menus](/content-management/menus/#define-in-site-configuration). ### minify @@ -419,7 +419,7 @@ Maximum number of items in the RSS feed. ### sectionPagesMenu -See ["Section Menu for Lazy Bloggers"](/templates/menu-templates/#section-menu-for-lazy-bloggers). +See [Menus](/content-management/menus/#define-in-site-configuration). ### security diff --git a/content/en/getting-started/directory-structure.md b/content/en/getting-started/directory-structure.md index b2cd0e447..3c74a3d58 100644 --- a/content/en/getting-started/directory-structure.md +++ b/content/en/getting-started/directory-structure.md @@ -85,7 +85,7 @@ From **Hugo 0.31** you can have multiple static directories. [`layouts`]: /templates/ [`static`]: /content-management/static-files/ [`resources`]: /getting-started/configuration/#configure-file-caches -[lists]: /templates/list/ +[lists]: /templates/lists/ [pagevars]: /variables/page/ [partials]: /templates/partials/ [searchconsole]: https://support.google.com/webmasters/answer/9008080#zippy=%2Chtml-file-upload diff --git a/content/en/hosting-and-deployment/hosting-on-netlify.md b/content/en/hosting-and-deployment/hosting-on-netlify.md index 254f993dc..ac9777a3a 100644 --- a/content/en/hosting-and-deployment/hosting-on-netlify.md +++ b/content/en/hosting-and-deployment/hosting-on-netlify.md @@ -101,7 +101,7 @@ See [this blog post](https://www.netlify.com/blog/2017/04/11/netlify-plus-hugo-0 ## Use Hugo Themes with Netlify -The [`git clone` method for installing themes][installthemes] is not supported by Netlify. If you were to use `git clone`, it would require you to recursively remove the `.git` subdirectory from the theme folder and would therefore prevent compatibility with future versions of the theme. +The `git clone` method for installing themes is not supported by Netlify. If you were to use `git clone`, it would require you to recursively remove the `.git` subdirectory from the theme folder and would therefore prevent compatibility with future versions of the theme. A *better* approach is to install a theme as a proper git submodule. You can [read the GitHub documentation for submodules][ghsm] or those found on [Git's website][gitsm] for more information, but the command is similar to that of `git clone`: @@ -147,7 +147,6 @@ You now have a live website served over HTTPS, distributed through CDN, and conf [gitsm]: https://git-scm.com/book/en/v2/Git-Tools-Submodules [httpscustom]: https://www.netlify.com/docs/ssl/ [hugoversions]: https://github.com/netlify/build-image/blob/master/Dockerfile#L216 -[installthemes]: /themes/installing/ [netlify]: https://www.netlify.com/ [netlifysignup]: https://app.netlify.com/signup [Quick Start]: /getting-started/quick-start/ diff --git a/content/en/hugo-pipes/transform-to-css.md b/content/en/hugo-pipes/transform-to-css.md index cc15bc2a6..4fd804b2b 100644 --- a/content/en/hugo-pipes/transform-to-css.md +++ b/content/en/hugo-pipes/transform-to-css.md @@ -57,5 +57,5 @@ includePaths [string slice] ``` {{% note %}} -Setting `outputStyle` to `compressed` will handle Sass/SCSS files minification better than the more generic [`resources.Minify`]({{< ref "minification">}}). +Setting `outputStyle` to `compressed` will handle Sass/SCSS files minification better than the more generic [`resources.Minify`](/hugo-pipes/minification). {{% /note %}} diff --git a/content/en/news/0.11-relnotes/index.md b/content/en/news/0.11-relnotes/index.md index dc4115fe0..884e43449 100644 --- a/content/en/news/0.11-relnotes/index.md +++ b/content/en/news/0.11-relnotes/index.md @@ -9,15 +9,15 @@ categories: ["Releases"] - [Live Reload](/getting-started/usage/#livereload). Hugo will automatically reload the browser when the build is complete - Theme engine w/[Theme Repository](http://github.com/spf13/hugoThemes) - [Menu system](/content-management/menus/) with support for active page -- [Builders](/extras/builders) to quickly create a new site, content or theme -- [XML sitemap](/templates/sitemap) generation -- [Integrated Disqus](/extras/comments) support -- Streamlined [template organization](/templates/overview) +- [Builders](/commands/hugo_new) to quickly create a new site, content or theme +- [XML sitemap](/templates/sitemap-template) generation +- [Integrated Disqus](/content-management/comments) support +- Streamlined [template organization](/templates/introduction) - Brand new docs site - Support for publishDate which allows for posts to be dated in the future -- More [sort](/functions/sort/#readout) options +- More [sort](/functions/sort) options - Logging support - Much better error handling - More informative verbose output -- Renamed Indexes > [Taxonomies](/taxonomies/overview) +- Renamed Indexes > [Taxonomies](/content-management/taxonomies/) - Renamed Chrome > [Partials](/templates/partials) diff --git a/content/en/news/0.12-relnotes/index.md b/content/en/news/0.12-relnotes/index.md index 0c62ea5b1..0209c5811 100644 --- a/content/en/news/0.12-relnotes/index.md +++ b/content/en/news/0.12-relnotes/index.md @@ -14,16 +14,16 @@ This release represents over 90 code commits from 28 different contributors. - 10 [new themes](https://github.com/spf13/hugoThemes) created by the community - fully themable [partials](/templates/partials/) - [404 template](/templates/404/) support in themes -- [shortcode](/extras/shortcodes/) support in themes +- [shortcode](/content-management/shortcodes/) support in themes - [views](/templates/views/) support in themes -- inner [shortcode](/extras/shortcodes/) content now treated as markdown +- inner [shortcode](/content-management/shortcodes) content now treated as markdown - support for header ids in markdown (# header {#myid}) - [where](/functions/where/) template function to filter lists of content, taxonomies, etc. -- [groupby](/templates/list) & [groupbydate](/templates/list) methods to group pages -- taxonomy [pages list](/taxonomies/methods/) now sortable, filterable, limitable & groupable +- [groupby](/templates/lists#by-page-field) & [groupbydate](/templates/lists/#by-date-1) methods to group pages +- taxonomy [pages list](/templates/taxonomy-templates#taxonomy-methods) now sortable, filterable, limitable & groupable - general cleanup to taxonomies & documentation to make it more clear and consistent - [showcase](/showcase/) returned and has been expanded - pretty links now always have trailing slashes -- [baseurl](/overview/configuration/) can now include a subdirectory +- [baseurl](/getting-started/configuration#baseurl) can now include a subdirectory - better feedback about draft & future post rendering - a variety of improvements to [the website](/) diff --git a/content/en/news/0.14-relnotes/index.md b/content/en/news/0.14-relnotes/index.md index 9b7928b47..d70d217eb 100644 --- a/content/en/news/0.14-relnotes/index.md +++ b/content/en/news/0.14-relnotes/index.md @@ -16,7 +16,7 @@ This release represents over **240 contributions by 36 contributors** to the mai Big shout out to [@bep](https://github.com/bep) who led the development of Hugo this release, [@anthonyfok](https://github.com/anthonyfok), [@eparis](https://github.com/eparis), [@SchumacherFM](https://github.com/SchumacherFM), [@RickCogley](https://github.com/RickCogley) & [@mdhender](https://github.com/mdhender) for their significant contributions and [@tatsushid](https://github.com/tatsushid) for his continuous improvements to the templates. Also a big thanks to all the theme creators. 11 new themes have been added since last release and the [hugoThemes repo now has previews of all of them](https://github.com/spf13/hugoThemes/blob/master/README.md#theme-list). Hugo also depends on a lot of other great projects. A big thanks to all of our dependencies inclding: -[cobra](https://github.com/spf13/cobra), [viper](https://github.com/spf13/viper), [blackfriday](https://github.com/russross/blackfriday), [pflag](https://github.com/spf13/pflag), [HugoThemes](https://github.com/spf13/hugothemes), [BurntSushi/Toml](github.com/BurntSushi/toml), [goYaml](https://github.com/go-yaml/yaml/tree/v2), and the Go standard library. +[cobra](https://github.com/spf13/cobra), [viper](https://github.com/spf13/viper), [blackfriday](https://github.com/russross/blackfriday), [pflag](https://github.com/spf13/pflag), [HugoThemes](https://github.com/spf13/hugothemes), [BurntSushi/Toml](https://github.com/BurntSushi/toml), [goYaml](https://github.com/go-yaml/yaml/tree/v2), and the Go standard library. ## New features - Support for all file types in content directory. diff --git a/content/en/news/0.20-relnotes/index.md b/content/en/news/0.20-relnotes/index.md index 27e4d48f7..2f598a33f 100644 --- a/content/en/news/0.20-relnotes/index.md +++ b/content/en/news/0.20-relnotes/index.md @@ -9,7 +9,7 @@ author: bep aliases: [/0-20/] --- -Hugo `0.20` introduces the powerful and long sought after feature [Custom Output Formats](http://gohugo.io/extras/output-formats/); Hugo isn’t just that “static HTML with an added RSS feed” anymore. _Say hello_ to calendars, e-book formats, Google AMP, and JSON search indexes, to name a few ( [#2828](//github.com/gohugoio/hugo/issues/2828) ). +Hugo `0.20` introduces the powerful and long sought after feature [Custom Output Formats](http://gohugo.io/extras/output-formats/); Hugo isn’t just that “static HTML with an added RSS feed” anymore. _Say hello_ to calendars, e-book formats, Google AMP, and JSON search indexes, to name a few ( [#2828](https://github.com/gohugoio/hugo/issues/2828) ). This release represents **over 180 contributions by over 30 contributors** to the main Hugo code base. Since last release Hugo has **gained 1100 stars, 20 new contributors and 5 additional themes.** @@ -19,15 +19,15 @@ Hugo now has: * 495+ contributors * 156+ themes -[@bep](//github.com/bep) still leads the Hugo development with his witty Norwegian humor, and once again contributed a significant amount of additions. Also a big shoutout to [@digitalcraftsman](//github.com/digitalcraftsman) for his relentless work on keeping the documentation and the themes site in pristine condition, and [@moorereason](//github.com/moorereason) and [@bogem](//github.com/bogem) for their ongoing contributions. +[@bep](https://github.com/bep) still leads the Hugo development with his witty Norwegian humor, and once again contributed a significant amount of additions. Also a big shoutout to [@digitalcraftsman](https://github.com/digitalcraftsman) for his relentless work on keeping the documentation and the themes site in pristine condition, and [@moorereason](https://github.com/moorereason) and [@bogem](https://github.com/bogem) for their ongoing contributions. ## Other Highlights -[@bogem](//github.com/bogem) has also contributed TOML as an alternative and much simpler format for language/i18n files ([#3200](//github.com/gohugoio/hugo/issues/3200)). A feature you will appreciate when you start to work on larger translations. +[@bogem](https://github.com/bogem) has also contributed TOML as an alternative and much simpler format for language/i18n files ([#3200](https://github.com/gohugoio/hugo/issues/3200)). A feature you will appreciate when you start to work on larger translations. -Also, there have been some important updates in the Emacs Org-mode handling: [@chaseadamsio](//github.com/chaseadamsio) has fixed the newline-handling ( [#3126](//github.com/gohugoio/hugo/issues/3126) ) and [@clockoon](//github.com/clockoon) has added basic footnote support. +Also, there have been some important updates in the Emacs Org-mode handling: [@chaseadamsio](https://github.com/chaseadamsio) has fixed the newline-handling ( [#3126](https://github.com/gohugoio/hugo/issues/3126) ) and [@clockoon](https://github.com/clockoon) has added basic footnote support. -Worth mentioning is also the ongoing work that [@rdwatters](//github.com/rdwatters) and [@budparr](//github.com/budparr) is doing to re-do the [gohugo.io](https://gohugo.io/) site, including a total restructuring and partial rewrite of the documentation. It is getting close to finished, and it looks fantastic! +Worth mentioning is also the ongoing work that [@rdwatters](https://github.com/rdwatters) and [@budparr](https://github.com/budparr) is doing to re-do the [gohugo.io](https://gohugo.io/) site, including a total restructuring and partial rewrite of the documentation. It is getting close to finished, and it looks fantastic! ## Notes @@ -35,38 +35,38 @@ Worth mentioning is also the ongoing work that [@rdwatters](//github.com/rdwatte * The deprecated `.RSSlink` is now removed. Use `.RSSLink`. * `RSSUri` is deprecated and will be removed in a future Hugo version, replace it with an output format definition. * The deprecated `.Site.GetParam` is now removed, use `.Site.Param`. -* Hugo does no longer append missing trailing slash to `baseURL` set as a command line parameter, making it consistent with how it behaves from site config. [#3262](//github.com/gohugoio/hugo/issues/3262) +* Hugo does no longer append missing trailing slash to `baseURL` set as a command line parameter, making it consistent with how it behaves from site config. [#3262](https://github.com/gohugoio/hugo/issues/3262) ## Enhancements * Hugo `0.20` is built with Go 1.8.1. -* Add `.Site.Params.mainSections` that defaults to the section with the most pages. Plan is to get themes to use this instead of the hardcoded `blog` in `where` clauses. [#3206](//github.com/gohugoio/hugo/issues/3206) -* File extension is now configurable. [#320](//github.com/gohugoio/hugo/issues/320) -* Improve `markdownify` template function performance. [#3292](//github.com/gohugoio/hugo/issues/3292) -* Add taxonomy terms’ pages to `.Data.Pages` [#2826](//github.com/gohugoio/hugo/issues/2826) +* Add `.Site.Params.mainSections` that defaults to the section with the most pages. Plan is to get themes to use this instead of the hardcoded `blog` in `where` clauses. [#3206](https://github.com/gohugoio/hugo/issues/3206) +* File extension is now configurable. [#320](https://github.com/gohugoio/hugo/issues/320) +* Improve `markdownify` template function performance. [#3292](https://github.com/gohugoio/hugo/issues/3292) +* Add taxonomy terms’ pages to `.Data.Pages` [#2826](https://github.com/gohugoio/hugo/issues/2826) * Change `RSS` description from full `.Content` to `.Summary`. -* Ignore “.” dirs in `hugo --cleanDestinationDir` [#3202](//github.com/gohugoio/hugo/issues/3202) -* Allow `jekyll import` to accept both `2006-01-02` and `2006-1-2` date format [#2738](//github.com/gohugoio/hugo/issues/2738) -* Raise the default `rssLimit` [#3145](//github.com/gohugoio/hugo/issues/3145) -* Unify section list vs single template lookup order [#3116](//github.com/gohugoio/hugo/issues/3116) -* Allow `apply` to be used with the built-in Go template funcs `print`, `printf` and `println`. [#3139](//github.com/gohugoio/hugo/issues/3139) +* Ignore “.” dirs in `hugo --cleanDestinationDir` [#3202](https://github.com/gohugoio/hugo/issues/3202) +* Allow `jekyll import` to accept both `2006-01-02` and `2006-1-2` date format [#2738](https://github.com/gohugoio/hugo/issues/2738) +* Raise the default `rssLimit` [#3145](https://github.com/gohugoio/hugo/issues/3145) +* Unify section list vs single template lookup order [#3116](https://github.com/gohugoio/hugo/issues/3116) +* Allow `apply` to be used with the built-in Go template funcs `print`, `printf` and `println`. [#3139](https://github.com/gohugoio/hugo/issues/3139) ## Fixes -* Fix deadlock in `getJSON` [#3211](//github.com/gohugoio/hugo/issues/3211) -* Make sure empty terms pages are created. [#2977](//github.com/gohugoio/hugo/issues/2977) -* Fix base template lookup order for sections [#2995](//github.com/gohugoio/hugo/issues/2995) +* Fix deadlock in `getJSON` [#3211](https://github.com/gohugoio/hugo/issues/3211) +* Make sure empty terms pages are created. [#2977](https://github.com/gohugoio/hugo/issues/2977) +* Fix base template lookup order for sections [#2995](https://github.com/gohugoio/hugo/issues/2995) * `URL` fixes: - * Fix pagination URLs with `baseURL` with sub-root and `canonifyUrls=false` [#1252](//github.com/gohugoio/hugo/issues/1252) - * Fix pagination URL for resources with “.” in name [#2110](//github.com/gohugoio/hugo/issues/2110) [#2374](//github.com/gohugoio/hugo/issues/2374) [#1885](//github.com/gohugoio/hugo/issues/1885) - * Handle taxonomy names with period [#3169](//github.com/gohugoio/hugo/issues/3169) - * Handle `uglyURLs` ambiguity in `Permalink` [#3102](//github.com/gohugoio/hugo/issues/3102) - * Fix `Permalink` for language-roots wrong when `uglyURLs` is `true` [#3179](//github.com/gohugoio/hugo/issues/3179) - * Fix misc case issues for `URLs` [#1641](//github.com/gohugoio/hugo/issues/1641) - * Fix for taxonomies URLs when `uglyUrls=true` [#1989](//github.com/gohugoio/hugo/issues/1989) - * Fix empty `RSSLink` for list pages with content page. [#3131](//github.com/gohugoio/hugo/issues/3131) -* Correctly identify regular pages on the form “my_index_page.md” [#3234](//github.com/gohugoio/hugo/issues/3234) -* `Exit -1` on `ERROR` in global logger [#3239](//github.com/gohugoio/hugo/issues/3239) -* Document hugo `help command` [#2349](//github.com/gohugoio/hugo/issues/2349) -* Fix internal `Hugo` version handling for bug fix releases. [#3025](//github.com/gohugoio/hugo/issues/3025) -* Only return `RSSLink` for pages that actually have a RSS feed. [#1302](//github.com/gohugoio/hugo/issues/1302) \ No newline at end of file + * Fix pagination URLs with `baseURL` with sub-root and `canonifyUrls=false` [#1252](https://github.com/gohugoio/hugo/issues/1252) + * Fix pagination URL for resources with “.” in name [#2110](https://github.com/gohugoio/hugo/issues/2110) [#2374](https://github.com/gohugoio/hugo/issues/2374) [#1885](https://github.com/gohugoio/hugo/issues/1885) + * Handle taxonomy names with period [#3169](https://github.com/gohugoio/hugo/issues/3169) + * Handle `uglyURLs` ambiguity in `Permalink` [#3102](https://github.com/gohugoio/hugo/issues/3102) + * Fix `Permalink` for language-roots wrong when `uglyURLs` is `true` [#3179](https://github.com/gohugoio/hugo/issues/3179) + * Fix misc case issues for `URLs` [#1641](https://github.com/gohugoio/hugo/issues/1641) + * Fix for taxonomies URLs when `uglyUrls=true` [#1989](https://github.com/gohugoio/hugo/issues/1989) + * Fix empty `RSSLink` for list pages with content page. [#3131](https://github.com/gohugoio/hugo/issues/3131) +* Correctly identify regular pages on the form “my_index_page.md” [#3234](https://github.com/gohugoio/hugo/issues/3234) +* `Exit -1` on `ERROR` in global logger [#3239](https://github.com/gohugoio/hugo/issues/3239) +* Document hugo `help command` [#2349](https://github.com/gohugoio/hugo/issues/2349) +* Fix internal `Hugo` version handling for bug fix releases. [#3025](https://github.com/gohugoio/hugo/issues/3025) +* Only return `RSSLink` for pages that actually have a RSS feed. [#1302](https://github.com/gohugoio/hugo/issues/1302) diff --git a/content/en/news/0.20.1-relnotes/index.md b/content/en/news/0.20.1-relnotes/index.md index 109737bb3..563f2e031 100644 --- a/content/en/news/0.20.1-relnotes/index.md +++ b/content/en/news/0.20.1-relnotes/index.md @@ -9,7 +9,7 @@ author: bep aliases: [/0-20-1/] --- -* Fix logic for base template in work dir vs in the theme [#3323](//github.com/gohugoio/hugo/issues/3323) -* camelCased templates (partials, shortcodes etc.) not found [#3333](//github.com/gohugoio/hugo/issues/3333) -* Live-reload fails with `_index.md` with paginator [#3315](//github.com/gohugoio/hugo/issues/3315) -* `rssURI` WARNING always shown [#3319](//github.com/gohugoio/hugo/issues/3319) \ No newline at end of file +* Fix logic for base template in work dir vs in the theme [#3323](https://github.com/gohugoio/hugo/issues/3323) +* camelCased templates (partials, shortcodes etc.) not found [#3333](https://github.com/gohugoio/hugo/issues/3333) +* Live-reload fails with `_index.md` with paginator [#3315](https://github.com/gohugoio/hugo/issues/3315) +* `rssURI` WARNING always shown [#3319](https://github.com/gohugoio/hugo/issues/3319) diff --git a/content/en/news/0.20.2-relnotes/index.md b/content/en/news/0.20.2-relnotes/index.md index 2e67d20ea..214fe01a5 100644 --- a/content/en/news/0.20.2-relnotes/index.md +++ b/content/en/news/0.20.2-relnotes/index.md @@ -9,7 +9,7 @@ author: bep aliases: [/0-20-2/] --- -Hugo `0.20.2` adds support for plain text partials included into `HTML` templates. This was a side-effect of the big new [Custom Output Format](https://gohugo.io/extras/output-formats/) feature in `0.20`, and while the change was intentional and there was an ongoing discussion about fixing it in [#3273](//github.com/gohugoio/hugo/issues/3273), it did break some themes. There were valid workarounds for these themes, but we might as well get it right. +Hugo `0.20.2` adds support for plain text partials included into `HTML` templates. This was a side-effect of the big new [Custom Output Format](https://gohugo.io/extras/output-formats/) feature in `0.20`, and while the change was intentional and there was an ongoing discussion about fixing it in [#3273](https://github.com/gohugoio/hugo/issues/3273), it did break some themes. There were valid workarounds for these themes, but we might as well get it right. The most obvious use case for this is inline `CSS` styles, which you now can do without having to name your partials with a `html` suffix. @@ -44,4 +44,4 @@ Add “CSS” to your home page’s `outputs` list, create the template `/layout {{ with .OutputFormats.Get "css" }} - {{ end }}` \ No newline at end of file + {{ end }}` diff --git a/content/en/news/0.63.0-relnotes/index.md b/content/en/news/0.63.0-relnotes/index.md index 899dfdb39..2410d3dcd 100644 --- a/content/en/news/0.63.0-relnotes/index.md +++ b/content/en/news/0.63.0-relnotes/index.md @@ -6,8 +6,6 @@ description: "In Hugo 0.63 we have improved the base template lookup logic, and categories: ["Releases"] --- -**Note:** There is already a [patch release](/news/0.63.1-relnotes/) with some fixes. - Hugo `0.63` is, in general, **considerably faster and more memory effective** (see the site-building benchmarks below comparing it to `v0.62`). Not that we are particularly concerned about Hugo's build speed. We leave that to others. But we would hate if it got slower, so we have a comprehensive benchmark suite. And when we needed to simplify the template handling code to solve a concurrency issue, it also became more effective. And as a bonus, we also finally got the [base template lookup order](https://gohugo.io/templates/base/#base-template-lookup-order) that you really, really wanted! ```bash @@ -119,8 +117,3 @@ Hugo now has: * Fix 0.62.1 server rebuild slowdown regression [17af79a0](https://github.com/gohugoio/hugo/commit/17af79a03e249a731cf5634ffea23ca00774333d) [@bep](https://github.com/bep) [#6784](https://github.com/gohugoio/hugo/issues/6784) * Fix blog not building [d61bee5e](https://github.com/gohugoio/hugo/commit/d61bee5e0916b5d2b388e66ef85c336312a21a06) [@colonelpopcorn](https://github.com/colonelpopcorn) [#6752](https://github.com/gohugoio/hugo/issues/6752) - - - - - diff --git a/content/en/news/lets-celebrate-hugos-5th-birthday/index.md b/content/en/news/lets-celebrate-hugos-5th-birthday/index.md index 9912027b5..08e1fbabd 100644 --- a/content/en/news/lets-celebrate-hugos-5th-birthday/index.md +++ b/content/en/news/lets-celebrate-hugos-5th-birthday/index.md @@ -78,7 +78,7 @@ Related to this is also to add a configurable "Markdown URL rewriter", which sho These are the items that first come to mind if you ask me to think even further ahead: Dependency manager for Theme Components -: In Hugo `0.42` we added [Theme Components](/themes/theme-components/) and Theme Inheritance. With SCSS support in Hugo `0.43`, which also follows the same project/themes precedence order (add `_variables.scss` to your project, configure SASS colour variables in `config.toml`), we have a solid foundation for creating easy to use and extensible themes. But we are missing some infrastructure around this. We have a site with 235+ [themes](https://themes.gohugo.io/)[^themes] listed, but you currently need to do some added work to get the theme up and running for your site. In the Go world, we don't have NPM to use, which is a curse and a blessing, but I have some ideas about building a simple dependency manager into Hugo, modelled after how Go is doing it (`hugo install`). You should be able to configure what theme and theme components you want to use, and Hugo should handle the installation of the correct versions. This should make it easier for the user, but it would also enable community driven and even commercial "theme stores". +: In Hugo `0.42` we added [Theme Components](/hugo-modules/theme-components) and Theme Inheritance. With SCSS support in Hugo `0.43`, which also follows the same project/themes precedence order (add `_variables.scss` to your project, configure SASS colour variables in `config.toml`), we have a solid foundation for creating easy to use and extensible themes. But we are missing some infrastructure around this. We have a site with 235+ [themes](https://themes.gohugo.io/)[^themes] listed, but you currently need to do some added work to get the theme up and running for your site. In the Go world, we don't have NPM to use, which is a curse and a blessing, but I have some ideas about building a simple dependency manager into Hugo, modelled after how Go is doing it (`hugo install`). You should be able to configure what theme and theme components you want to use, and Hugo should handle the installation of the correct versions. This should make it easier for the user, but it would also enable community driven and even commercial "theme stores". {{< imgproc graph-themes Fit "600x400" >}} diff --git a/content/en/templates/data-templates.md b/content/en/templates/data-templates.md index 1586d3a54..30f708644 100644 --- a/content/en/templates/data-templates.md +++ b/content/en/templates/data-templates.md @@ -52,7 +52,7 @@ Data file|Template code ## Data Files in Themes -Data Files can also be used in [Hugo themes][themes]. +Data Files can also be used in themes. However, note that the theme data files are merged with the project directory taking precedence. That is, Given two files with the same name and relative path, the data in the file in the root project `data` directory will override the data from the file in the `themes//data` directory *for keys that are duplicated*). @@ -258,14 +258,13 @@ If you change any local file and the LiveReload is triggered, Hugo will read the [config]: /getting-started/configuration/ [csv]: https://tools.ietf.org/html/rfc4180 -[customize]: /themes/customizing/ +[customize]: /hugo-modules/theme-components/ [json]: https://www.ecma-international.org/publications/files/ECMA-ST/ECMA-404.pdf "Specification for JSON, JavaScript Object Notation" [LiveReload]: /getting-started/usage/#livereload [lookup]: /templates/lookup-order/ [markdownify]: /functions/markdownify/ [OAuth]: https://en.wikipedia.org/wiki/OAuth [partials]: /templates/partials/ -[themes]: /themes/ [toml]: https://github.com/toml-lang/toml [variadic]: https://en.wikipedia.org/wiki/Variadic_function [vars]: /variables/ diff --git a/content/en/templates/introduction.md b/content/en/templates/introduction.md index 5145b04be..14ebbda28 100644 --- a/content/en/templates/introduction.md +++ b/content/en/templates/introduction.md @@ -31,8 +31,7 @@ Go Templates are HTML files with the addition of [variables][variables] and [fun ### Access a Predefined Variable A _predefined variable_ could be a variable already existing in the -current scope (like the `.Title` example in the [Variables]({{< relref -"#variables" >}}) section below) or a custom variable (like the +current scope (like the `.Title` example in the [Variables](#variables) section below) or a custom variable (like the `$address` example in that same section). @@ -529,7 +528,7 @@ The templating engine will strip the content within the HTML comment, but will f ## Hugo Parameters -Hugo provides the option of passing values to your template layer through your [site configuration][config] (i.e. for site-wide values) or through the metadata of each specific piece of content (i.e. the [front matter]). You can define any values of any type and use them however you want in your templates, as long as the values are supported by the [front matter format]({{< ref "front-matter.md#front-matter-formats" >}}). +Hugo provides the option of passing values to your template layer through your [site configuration][config] (i.e. for site-wide values) or through the metadata of each specific piece of content (i.e. the [front matter]). You can define any values of any type and use them however you want in your templates, as long as the values are supported by the [front matter format](/content-management/front-matter#front-matter-formats). ## Use Content (`Page`) Parameters @@ -663,19 +662,19 @@ If you restrict front matter to the TOML format, and omit quotation marks surrou {{< /code >}} -[config]: {{< relref "getting-started/configuration" >}} [dotdoc]: https://golang.org/pkg/text/template/#hdr-Variables -[first]: {{< relref "functions/first" >}} -[front matter]: {{< relref "content-management/front-matter" >}} -[functions]: {{< relref "functions" >}} -[internal templates]: {{< relref "templates/internal" >}} -[isset]: {{< relref "functions/isset" >}} -[math]: {{< relref "functions/math" >}} -[pagevars]: {{< relref "variables/page" >}} -[param]: {{< relref "functions/param" >}} -[partials]: {{< relref "templates/partials" >}} -[relpermalink]: {{< relref "variables/page#page-variables" >}} -[safehtml]: {{< relref "functions/safehtml" >}} -[sitevars]: {{< relref "variables/site" >}} -[variables]: {{< relref "variables" >}} -[with]: {{< relref "functions/with" >}} +[config]: /getting-started/configuration +[first]: /functions/first +[front matter]: /content-management/front-matter +[functions]: /functions +[internal templates]: /templates/internal +[isset]: /functions/isset +[math]: /functions/math +[pagevars]: /variables/page +[param]: /functions/param +[partials]: /templates/partials +[relpermalink]: /variables/page#page-variables +[safehtml]: /functions/safehtml +[sitevars]: /variables/site +[variables]: /variables +[with]: /functions/with diff --git a/content/en/templates/lists.md b/content/en/templates/lists/index.md similarity index 99% rename from content/en/templates/lists.md rename to content/en/templates/lists/index.md index 03847707b..c78555d39 100644 --- a/content/en/templates/lists.md +++ b/content/en/templates/lists/index.md @@ -35,7 +35,7 @@ For template lookup order, see [Template Lookup](/templates/lookup-order/). The idea of a list page comes from the [hierarchical mental model of the web][mentalmodel] and is best demonstrated visually: -[![Image demonstrating a hierarchical website sitemap.](/images/site-hierarchy.svg)](/images/site-hierarchy.svg) +[![Image demonstrating a hierarchical website sitemap.](site-hierarchy.svg)](site-hierarchy.svg) ## List Defaults diff --git a/static/images/site-hierarchy.svg b/content/en/templates/lists/site-hierarchy.svg similarity index 100% rename from static/images/site-hierarchy.svg rename to content/en/templates/lists/site-hierarchy.svg diff --git a/content/en/templates/output-formats.md b/content/en/templates/output-formats.md index 0498c7e64..1aec917eb 100644 --- a/content/en/templates/output-formats.md +++ b/content/en/templates/output-formats.md @@ -251,7 +251,7 @@ The partial below is a plain text template (Output Format is `CSV`, and since th [base]: /templates/base/ [config]: /getting-started/configuration/ -[lookup order]: /templates/lookup/ +[lookup order]: /templates/lookup-order/ [media type]: https://en.wikipedia.org/wiki/Media_type [partials]: /templates/partials/ [page_kinds]: /templates/section-templates/#page-kinds diff --git a/content/en/templates/partials.md b/content/en/templates/partials.md index 1899f87d5..85aa33a50 100644 --- a/content/en/templates/partials.md +++ b/content/en/templates/partials.md @@ -197,10 +197,10 @@ The following `footer.html` partial template is used for [spf13.com](https://spf {{< /code >}} -[context]: /templates/introduction/ "The most easily overlooked concept to understand about Go templating is how the dot always refers to the current context." -[customize]: /themes/customizing/ "Hugo provides easy means to customize themes as long as users are familiar with Hugo's template lookup order." -[listtemps]: /templates/lists/ "To effectively leverage Hugo's system, see how Hugo handles list pages, where content for sections, taxonomies, and the homepage are listed and ordered." -[lookup order]: /templates/lookup-order/ "To keep your templating dry, read the documentation on Hugo's lookup order." -[partialcached]: /functions/partialcached/ "Use the partial cached function to improve build times in cases where Hugo can cache partials that don't need to be rendered with every page." -[singletemps]: /templates/single-page-templates/ "The most common form of template in Hugo is the single content template. Read the docs on how to create templates for individual pages." +[context]: /templates/introduction/ +[customize]: /hugo-modules/theme-components/ +[listtemps]: /templates/lists/ +[lookup order]: /templates/lookup-order/ +[partialcached]: /functions/partialcached/ +[singletemps]: /templates/single-page-templates/ [themes]: /themes/ diff --git a/content/en/templates/sitemap-template.md b/content/en/templates/sitemap-template.md index 9fc817020..b9469e0fa 100644 --- a/content/en/templates/sitemap-template.md +++ b/content/en/templates/sitemap-template.md @@ -79,7 +79,7 @@ You may disable sitemap generation in your site configuration: disableKinds = ['sitemap'] {{}} -[`publishDir`]: {{< relref "getting-started/configuration#publishdir" >}} +[`publishDir`]: /getting-started/configuration#publishdir [change frequency]: [priority]: [sitemap protocol]: diff --git a/content/en/templates/taxonomy-templates.md b/content/en/templates/taxonomy-templates.md index e9fc80525..86abeb678 100644 --- a/content/en/templates/taxonomy-templates.md +++ b/content/en/templates/taxonomy-templates.md @@ -177,16 +177,16 @@ There are two different templates that the use of taxonomies will require you to Both templates are covered in detail in the templates section. -A [list template](/templates/list/) is any template that will be used to render multiple pieces of content in a single html page. This template will be used to generate all the automatically created taxonomy pages. +A [list template](/templates/lists/) is any template that will be used to render multiple pieces of content in a single html page. This template will be used to generate all the automatically created taxonomy pages. -A [taxonomy terms template](/templates/terms/) is a template used to +A [taxonomy template](/templates/taxonomy-templates/) is a template used to generate the list of terms for a given template. There are four common ways you can display the data in your taxonomies in addition to the automatic taxonomy pages created by hugo -using the [list templates](/templates/list/): +using the [list templates](/templates/lists/): 1. For a given piece of content, you can list the terms attached 2. For a given piece of content, you can list other content with the same @@ -315,7 +315,7 @@ This example will list all taxonomies and their terms, as well as all the conten ## `.Site.GetPage` for Taxonomies -Because taxonomies are lists, the [`.GetPage` function][getpage] can be used to get all the pages associated with a particular taxonomy term using a terse syntax. The following ranges over the full list of tags on your site and links to each of the individual taxonomy pages for each term without having to use the more fragile URL construction of the ["List All Site Tags" example above]({{< relref "#example-list-all-site-tags" >}}): +Because taxonomies are lists, the [`.GetPage` function][getpage] can be used to get all the pages associated with a particular taxonomy term using a terse syntax. The following ranges over the full list of tags on your site and links to each of the individual taxonomy pages for each term without having to use the more fragile URL construction of the ["List All Site Tags" example above](#example-list-all-site-tags): {{< code file="links-to-all-tags.html" >}} {{ $taxo := "tags" }} diff --git a/content/en/troubleshooting/build-performance.md b/content/en/troubleshooting/build-performance.md index ea31ef84b..e17f41072 100644 --- a/content/en/troubleshooting/build-performance.md +++ b/content/en/troubleshooting/build-performance.md @@ -91,4 +91,4 @@ parameters to `partialCached` beyond the initial context. See the `partialCached` documentation for more details. {{% /tip %}} -[partialCached]:{{< ref "/functions/partialCached.md" >}} +[partialCached]: /functions/partialCached diff --git a/content/en/variables/page.md b/content/en/variables/page.md index 681f2d1f7..02eb6932d 100644 --- a/content/en/variables/page.md +++ b/content/en/variables/page.md @@ -29,7 +29,7 @@ The following is a list of page-level variables. Many of these will be defined i : aliases of this page .Ancestors -: get the ancestors of each page, simplify [breadcrumb navigation]({{< relref "content-management/sections#example-breadcrumb-navigation" >}}) implementation complexity +: get the ancestors of each page, simplify [breadcrumb navigation](/content-management/sections#example-breadcrumb-navigation) implementation complexity .BundleType : the [bundle] type: `leaf`, `branch`, or an empty string if the page is not a bundle. @@ -107,7 +107,7 @@ See also `.ExpiryDate`, `.Date`, `.PublishDate`, and [`.GitInfo`][gitinfo]. .Pages : a collection of associated pages. This value will be `nil` within - the context of regular content pages. See [`.Pages`]({{< relref "page.md#pages" >}}). + the context of regular content pages. See [`.Pages`](#pages). .Permalink : the Permanent link for this page; see [Permalinks](/content-management/urls/) @@ -355,6 +355,6 @@ The top-level key will be preferred. Therefore, the following method, when appli [gitinfo]: /variables/git/ [File Variables]: /variables/files/ -[bundle]: {{< relref "content-management/page-bundles" >}} +[bundle]: /content-management/page-bundles [scratch]: /functions/scratch [store]: /functions/store diff --git a/content/en/variables/site.md b/content/en/variables/site.md index a78244db0..fb113198c 100644 --- a/content/en/variables/site.md +++ b/content/en/variables/site.md @@ -84,10 +84,10 @@ All the methods below, e.g. `.Site.RegularPages` can also be reached via the glo : all the menus in the site. .Site.Pages -: array of all content ordered by Date with the newest first. This array contains only the pages in the current language. See [`.Site.Pages`]({{< relref "site.md#site-pages" >}}). +: array of all content ordered by Date with the newest first. This array contains only the pages in the current language. See [`.Site.Pages`](#site-pages). .Site.RegularPages -: a shortcut to the *regular* page collection. `.Site.RegularPages` is equivalent to `where .Site.Pages "Kind" "page"`. See [`.Site.Pages`]({{< relref "site.md#site-pages" >}}). +: a shortcut to the *regular* page collection. `.Site.RegularPages` is equivalent to `where .Site.Pages "Kind" "page"`. See [`.Site.Pages`](#site-pages). .Site.Sections : top-level directories of the site.