aboutsummaryrefslogtreecommitdiffhomepage
path: root/content/en/content-management/organization/index.md
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <[email protected]>2023-12-04 15:14:18 +0100
committerBjørn Erik Pedersen <[email protected]>2023-12-04 15:14:18 +0100
commit35dec7c96f7ee3eb17dd444f7067f0c776fb56ae (patch)
treef2fa4f4c1a0fe6bfd47cb84982d5f4a73bc306f2 /content/en/content-management/organization/index.md
parentaaaf1c8df5d6aa061609d20510f7fa6c42e5cc1a (diff)
downloadhugo-35dec7c96f7ee3eb17dd444f7067f0c776fb56ae.tar.gz
hugo-35dec7c96f7ee3eb17dd444f7067f0c776fb56ae.zip
Squashed 'docs/' changes from 4d936aee6..4dd2d6415
4dd2d6415 Fix erroridf example 9ae8e9199 Clarify highlight options f3943f9c8 Fix typo b57ea5ac8 Add field to glossary of terms 3191e35b4 Clarify comment in the new-in shortcode 870c8d35c Correct description of Ref and RelRef page methods c9df50e6e Specify encoding in description of crypto functions 749bb37e2 Add Ref, RelRef, and Site shortcode methods 994d4374b Update fmt functions 740f5ef96 Misc additions 77acdcdb6 Remove rssLimit from root config documentation df84a1795 Document the openapi3.Unmarshal function 24236f57d Miscellaneous edits and corrections 41b54d421 Hide the "new in" button after some period of time 3c1ebac31 Update Ancestors.md e699eb313 Add new-in tags to select functions and methods 5c41f0bf8 Clarify time.Format method f7bd43ae1 Add link to built-in render hook for GoAT diagrams 06f9cd4c9 Document the diagrams.Goat function 5e432e12d Adjust quick reference weights fc915efd6 Update FAQ 5bccf8b19 Use LinkTitle consistently in examples 36f207f3a Add page collection quick reference 699de883d Inlcude example of newScratch.Values 9bb7f8c78 Include RenderString example for emoji shortcodes 783fdd3ac Fix typo 26d5a4399 Fix typo c7e86f0cf Fix typo ad2a82fbd Clarify data type returned by partial and partialCached 1de5a52dd Miscellaneous corrections 3509e1b4d Update configuration-markup.md 8c6a9bf02 Clairfy figure shortcode output c9d0dc8fb Update Markdownify.md 0c4bc1447 Update theme 0f0ab2ade Add methods deprecated in v0.120.0 e1c6ecd0f Miscellaneous edits ec53b55b9 netlify: Hugo 0.120.4 23a1f3fd5 templates/internal.md: Correct GoogleAnalytics key name 6dcfa9a82 Update troubleshooting section 0c8857e8f Adjust code and code-toggle shortcodes 8820264d3 Reduce number of site audit warnings 526d06b90 Clarify hint option in image processing spec 310849daa Image Processing: Improve sentence and fix code sample 5bb67bfd4 Revert "Image Processing: Improve sentence and fix code sample" (#2318) 77c926fde Image Processing: Improve sentence and fix code sample 52179fb18 Miscellaneous edits f4e886715 Revert change to hugo.work c410fefa8 Update theme 8b72dfedd Rework where function documentation f35a7126f Minor edits to global page function 903b42ebc Cleanup shortcode calls c9247e98d Update documentation.md dff3c4abb Clean up build option descriptions and examples f46d31308 Use consistent signatures 2af2470b5 Minor correction to resources.GetRemote 45ec53fe0 Remove superfluous shortcode param 2a0544757 Improve deployment documentation 3cf36a7fc Clarify lang keyword f10d6495d Update front-matter.md dc94e20be Add Sveltia to CMS list b15d6d670 Update front-ends.md bb41588b2 Update FormatCurrency.md b40fff396 Add showcase for hidden sections without index.html 71316e181 Improve image filter examples d46f0b1d8 Miscellaneous edits ad3f9cdb6 Adjust quick reference guides 8657804ba Update theme d9e981147 Miscellaneous corrections 508666575 Miscellaneous updates 80b2241f9 Miscellaneous updates 723a827fd Namespace functions and methods 40212779a netlify: Hugo 0.120.3 66017c704 Bump GitHub workflows to latest versions db0f1e682 Update related.md 7e758c23b netlify: Hugo 0.120.2 641ba3976 Update configuration.md d2a9909d9 Update rss.md 7eb59d7a2 netlify: Hugo 0.120.1 708c351c4 Document debug.Timer 28e2388c2 Add new-in tag to images.Padding ee24cffb5 Add new-in tags to hugo.IsDevelopment and hugo.IsServer aa47ca023 netlify: Hugo 0.120.0 9c3e606fc docs: Regen docshelper 159fd971e commands/new: Remove format flag from new content cmd 9f7878092 Merge commit 'aaaf1c8df5d6aa061609d20510f7fa6c42e5cc1a' 65b2dd324 docs: Regenerate docshelper 2be620663 resources/images: Create padding image filter c777d6c5e Merge commit '3710a5ec7efe6baca6e452f43632c05d22bab3c4' 24f2afeb2 Merge commit 'e509cac533600cf4fa8382c9cdab78ddd82db688' 3f947c19a hugolib: Deprecate .Site.DisqusShortname 6bd1af892 hugolib: Deprecate .Site.GoogleAnalytics 78becc6ee tpl/tplimpl: Deprecate .Site.Social usage with internal templates e3ec2a4f2 common/hugo: Add hugo.IsServer and hugo.IsDevelopment git-subtree-dir: docs git-subtree-split: 4dd2d641531f74025ed9f51ea5a961e936988cfb
Diffstat (limited to 'content/en/content-management/organization/index.md')
-rw-r--r--content/en/content-management/organization/index.md35
1 files changed, 14 insertions, 21 deletions
diff --git a/content/en/content-management/organization/index.md b/content/en/content-management/organization/index.md
index 2c0d2e604..22b341fcf 100644
--- a/content/en/content-management/organization/index.md
+++ b/content/en/content-management/organization/index.md
@@ -2,14 +2,14 @@
title: Content organization
linkTitle: Organization
description: Hugo assumes that the same structure that works to organize your source content is used to organize the rendered site.
-categories: [fundamentals,content management]
+categories: [content management,fundamentals]
keywords: [sections,content,organization,bundle,resources]
menu:
docs:
parent: content-management
weight: 20
-toc: true
weight: 20
+toc: true
aliases: [/content/sections/]
---
@@ -19,16 +19,14 @@ Hugo `0.32` announced page-relative images and other resources packaged into `Pa
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" >}}
+{{< imgproc "1-featured-content-bundles.png" "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.
{{< /imgproc >}}
-
{{% note %}}
The bundle documentation is a **work in progress**. We will publish more comprehensive docs about this soon.
{{% /note %}}
-
## Organization of content source
In Hugo, your content should be organized in a manner that reflects the rendered website.
@@ -41,33 +39,31 @@ Without any additional configuration, the following will automatically work:
.
└── content
└── about
- | └── index.md // <- https://example.com/about/
+ | └── index.md // <- https://example.org/about/
├── posts
- | ├── firstpost.md // <- https://example.com/posts/firstpost/
+ | ├── firstpost.md // <- https://example.org/posts/firstpost/
| ├── happy
- | | └── ness.md // <- https://example.com/posts/happy/ness/
- | └── secondpost.md // <- https://example.com/posts/secondpost/
+ | | └── ness.md // <- https://example.org/posts/happy/ness/
+ | └── secondpost.md // <- https://example.org/posts/secondpost/
└── quote
- ├── first.md // <- https://example.com/quote/first/
- └── second.md // <- https://example.com/quote/second/
+ ├── first.md // <- https://example.org/quote/first/
+ └── second.md // <- https://example.org/quote/second/
```
## Path breakdown in Hugo
-
-The following demonstrates the relationships between your content organization and the output URL structure for your Hugo website when it renders. These examples assume you are [using pretty URLs][pretty], which is the default behavior for Hugo. The examples also assume a key-value of `baseURL = "https://example.com"` in your [site's configuration file][config].
+The following demonstrates the relationships between your content organization and the output URL structure for your Hugo website when it renders. These examples assume you are [using pretty URLs][pretty], which is the default behavior for Hugo. The examples also assume a key-value of `baseURL = "https://example.org"` in your [site's configuration file][config].
### Index pages: `_index.md`
`_index.md` has a special role in Hugo. It allows you to add front matter and content to your [list templates][lists]. These templates include those for [section templates], [taxonomy templates], [taxonomy terms templates], and your [homepage template].
{{% note %}}
-**Tip:** You can get a reference to the content and metadata in `_index.md` using the [`.Site.GetPage` function](/functions/getpage/).
+**Tip:** You can get a reference to the content and metadata in `_index.md` using the [`.Site.GetPage` function](/methods/page/getpage).
{{% /note %}}
You can create one `_index.md` for your homepage and one in each of your content sections, taxonomies, and taxonomy terms. The following shows typical placement of an `_index.md` that would contain content and front matter for a `posts` section list page on a Hugo website:
-
```txt
. url
. ⊢--^-⊣
@@ -88,17 +84,15 @@ At build, this will output to the following destination with the associated valu
⊢--------^---------⊣⊢-^-⊣
permalink
⊢----------^-------------⊣
-https://example.com/posts/index.html
+https://example.org/posts/index.html
```
The [sections] can be nested as deeply as you want. The important thing to understand is that to make the section tree fully navigational, at least the lower-most section must include a content file. (i.e. `_index.md`).
-
### Single pages in sections
Single content files in each of your sections will be rendered as [single page templates][singles]. Here is an example of a single `post` within `posts`:
-
```txt
path ("posts/my-first-hugo-post.md")
. ⊢-----------^------------⊣
@@ -117,10 +111,9 @@ When Hugo builds your site, the content will be output to the following destinat
⊢--------^--------⊣⊢-^--⊣⊢-------^---------⊣
permalink
⊢--------------------^---------------------⊣
-https://example.com/posts/my-first-hugo-post/index.html
+https://example.org/posts/my-first-hugo-post/index.html
```
-
## Paths explained
The following concepts provide more insight into the relationship between your project's organization and the default Hugo behavior when building output for the website.
@@ -147,7 +140,7 @@ The `url` is the entire URL path, defined by the file path and optionally overri
[config]: /getting-started/configuration/
[formats]: /content-management/formats/
[front matter]: /content-management/front-matter/
-[getpage]: /functions/getpage/
+[getpage]: /methods/page/getpage
[homepage template]: /templates/homepage/
[homepage]: /templates/homepage/
[lists]: /templates/lists/