From a7321b918c4f96c8719b35101396970eaa2d5c5d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=B6ren=20Weber?= Date: Mon, 22 Apr 2024 23:14:23 +0200 Subject: [PATCH] docs: don't publish unnecessary config files --- exampleSite/config/_default/hugo.toml | 2 +- exampleSite/content/cont/frontmatter/_index.en.md | 4 ++-- .../content/shortcodes/{ => include}/INCLUDE_ME.md | 0 .../shortcodes/{include.en.md => include/_index.en.md} | 10 +++++----- .../{include.pir.md => include/_index.pir.md} | 0 5 files changed, 8 insertions(+), 8 deletions(-) rename exampleSite/content/shortcodes/{ => include}/INCLUDE_ME.md (100%) rename exampleSite/content/shortcodes/{include.en.md => include/_index.en.md} (83%) rename exampleSite/content/shortcodes/{include.pir.md => include/_index.pir.md} (100%) diff --git a/exampleSite/config/_default/hugo.toml b/exampleSite/config/_default/hugo.toml index d60d6cfd9d..52d9110af0 100644 --- a/exampleSite/config/_default/hugo.toml +++ b/exampleSite/config/_default/hugo.toml @@ -200,7 +200,7 @@ title = "Hugo Relearn Theme" # just for this documentation to expose our config in the docs [[module.mounts]] source = 'config' - target = 'static/config' + target = 'assets/config' # just for this documentation to expose the GitHub hero image in the docs [[module.mounts]] source = '../images' diff --git a/exampleSite/content/cont/frontmatter/_index.en.md b/exampleSite/content/cont/frontmatter/_index.en.md index 30306037b0..0f0f56d530 100644 --- a/exampleSite/content/cont/frontmatter/_index.en.md +++ b/exampleSite/content/cont/frontmatter/_index.en.md @@ -10,14 +10,14 @@ Each Hugo page **has to define** a [frontmatter](https://gohugo.io/content/front The values reflect example options. The defaults can be taken from the [annotated example](#annotated-frontmatter-options) below. {{< multiconfig fm=true >}} -{{% include "cont/frontmatter/frontmatter.toml" %}} +{{% include "frontmatter.toml" %}} {{< /multiconfig >}} ## Annotated Frontmatter Options ````toml {title="toml"} +++ -{{% include "cont/frontmatter/frontmatter.toml" %}}+++ +{{% include "frontmatter.toml" %}}+++ ```` ## Some Detailed Examples diff --git a/exampleSite/content/shortcodes/INCLUDE_ME.md b/exampleSite/content/shortcodes/include/INCLUDE_ME.md similarity index 100% rename from exampleSite/content/shortcodes/INCLUDE_ME.md rename to exampleSite/content/shortcodes/include/INCLUDE_ME.md diff --git a/exampleSite/content/shortcodes/include.en.md b/exampleSite/content/shortcodes/include/_index.en.md similarity index 83% rename from exampleSite/content/shortcodes/include.en.md rename to exampleSite/content/shortcodes/include/_index.en.md index bc71785700..0756065178 100644 --- a/exampleSite/content/shortcodes/include.en.md +++ b/exampleSite/content/shortcodes/include/_index.en.md @@ -13,14 +13,14 @@ While the examples are using shortcodes with named parameter you are free to use {{% tab title="shortcode" %}} ````go -{{%/* include file="shortcodes/INCLUDE_ME.md" */%}} +{{%/* include file="shortcodes/include/INCLUDE_ME.md" */%}} ```` {{% /tab %}} {{% tab title="shortcode (positional)" %}} ````go -{{%/* include "shortcodes/INCLUDE_ME.md" */%}} +{{%/* include "shortcodes/include/INCLUDE_ME.md" */%}} ```` {{% /tab %}} @@ -29,7 +29,7 @@ While the examples are using shortcodes with named parameter you are free to use ````go {{ partial "shortcodes/include .html" (dict "page" . - "file" "shortcodes/INCLUDE_ME.md" + "file" "shortcodes/include/INCLUDE_ME.md" )}} ```` @@ -50,7 +50,7 @@ The included files can even contain Markdown and will be taken into account when ### Arbitrary Content ````go -{{%/* include "shortcodes/INCLUDE_ME.md" */%}} +{{%/* include "shortcodes/include/INCLUDE_ME.md" */%}} ```` -{{% include "shortcodes/INCLUDE_ME.md" %}} +{{% include "shortcodes/include/INCLUDE_ME.md" %}} diff --git a/exampleSite/content/shortcodes/include.pir.md b/exampleSite/content/shortcodes/include/_index.pir.md similarity index 100% rename from exampleSite/content/shortcodes/include.pir.md rename to exampleSite/content/shortcodes/include/_index.pir.md