summaryrefslogtreecommitdiffstats
path: root/docs/content/en
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2022-01-12 08:16:35 +0100
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2022-01-12 08:16:35 +0100
commit098254f175246c364bd6cc46a8b0420b768089bd (patch)
treee8c6ac23078a75bc034f557978634cbc828c80bc /docs/content/en
parentcdcd15b6c2abbb76fd95fbbf90365c56e82f46aa (diff)
parenta8e9fc699a6ff7d578f97a7c553ce844efad8fdb (diff)
Diffstat (limited to 'docs/content/en')
-rw-r--r--docs/content/en/about/security-model/index.md2
-rw-r--r--docs/content/en/content-management/image-processing/index.md2
-rw-r--r--docs/content/en/functions/images/index.md2
-rwxr-xr-xdocs/content/en/hugo-pipes/introduction.md34
-rw-r--r--docs/content/en/news/2021-12-17-no-more-releasenotes.md10
-rw-r--r--docs/content/en/news/2021/0.91.2-relnotes/featured.pngbin0 -> 131575 bytes
-rw-r--r--docs/content/en/news/2021/0.91.2-relnotes/index.md9
-rw-r--r--docs/content/en/templates/data-templates.md4
-rw-r--r--docs/content/en/variables/files.md2
-rw-r--r--docs/content/en/variables/git.md4
-rw-r--r--docs/content/en/variables/page.md4
11 files changed, 51 insertions, 22 deletions
diff --git a/docs/content/en/about/security-model/index.md b/docs/content/en/about/security-model/index.md
index aed925d49..0aec55560 100644
--- a/docs/content/en/about/security-model/index.md
+++ b/docs/content/en/about/security-model/index.md
@@ -35,7 +35,7 @@ But when developing and building your site, the runtime is the `hugo` executable
Hugo has a built-in security policy that restricts access to [os/exec](https://pkg.go.dev/os/exec), remote communication and similar.
-The defdault configuration is listed below. And build using features not whitelisted in the security policy will faill with a detailed message about what needs to be done. Most of these settings are whitelists (string or slice, [Regular Expressions](https://pkg.go.dev/regexp) or `none` which matches nothing).
+The default configuration is listed below. And build using features not whitelisted in the security policy will faill with a detailed message about what needs to be done. Most of these settings are whitelists (string or slice, [Regular Expressions](https://pkg.go.dev/regexp) or `none` which matches nothing).
{{< code-toggle config="security" />}}
diff --git a/docs/content/en/content-management/image-processing/index.md b/docs/content/en/content-management/image-processing/index.md
index 8f84145ac..0211f6fcd 100644
--- a/docs/content/en/content-management/image-processing/index.md
+++ b/docs/content/en/content-management/image-processing/index.md
@@ -305,7 +305,7 @@ bgColor = "#ffffff"
# disk space reasons more than anything.
# If you want it all, put ".*" in this config setting.
# Note that if neither this or ExcludeFields is set, Hugo will return a small
-# default set.
+# default set: GPS|Exif|Exposure[M|P|B]|Contrast|Resolution|Sharp|JPEG|Metering|Sensing|Saturation|ColorSpace|Flash|WhiteBalance
includeFields = ""
# Regexp matching the Exif fields you want to exclude. This may be easier to use
diff --git a/docs/content/en/functions/images/index.md b/docs/content/en/functions/images/index.md
index 350d005ee..92c6ff0da 100644
--- a/docs/content/en/functions/images/index.md
+++ b/docs/content/en/functions/images/index.md
@@ -128,7 +128,7 @@ images.GaussianBlur SIGMA
GaussianBlur creates a filter that applies a gaussian blur to an image.
-### Grayscale
+## Grayscale
{{% funcsig %}}
images.Grayscale
diff --git a/docs/content/en/hugo-pipes/introduction.md b/docs/content/en/hugo-pipes/introduction.md
index 7cace938a..babf9cdb8 100755
--- a/docs/content/en/hugo-pipes/introduction.md
+++ b/docs/content/en/hugo-pipes/introduction.md
@@ -18,25 +18,32 @@ toc: true
aliases: [/assets/]
---
-## Get Resource with resources.Get
+## Get Resource with resources.Get and resources.GetRemote
-In order to process an asset with Hugo Pipes, it must be retrieved as a `Resource` using `resources.Get`. The first argument can be either a local the path to file relative to the `asset` directory/directories or a remote URL.
+In order to process an asset with Hugo Pipes, it must be retrieved as a `Resource` using `resources.Get` or `resources.GetRemote`.
+
+With `resources.Get`, the first argument is a local path relative to the `assets` directory/directories:
```go-html-template
{{ $local := resources.Get "sass/main.scss" }}
-{{ $remote := resources.Get "https://www.example.com/styles.scss" }}
```
-`resources.Get` will always return `nil` if the resource could not be found.
+With `resources.GetRemote`, the first argument is a remote URL:
+
+```go-html-template
+{{ $remote := resources.GetRemote "https://www.example.com/styles.scss" }}
+```
+
+`resources.Get` and `resources.GetRemote` return `nil` if the resource is not found.
### Error Handling
-{{< new-in "0.90.1" >}}
+{{< new-in "0.91.0" >}}
-The return value from `resources.Get` includes an `.Err` method that will return an error if the call failed. If you want to just log any error as a `WARNING` you can use a construct similar to the one below.
+The return value from `resources.GetRemote` includes an `.Err` method that will return an error if the call failed. If you want to just log any error as a `WARNING` you can use a construct similar to the one below.
```go-html-template
-{{ with resources.Get "https://gohugo.io/images/gohugoio-card-1.png" }}
+{{ with resources.GetRemote "https://gohugo.io/images/gohugoio-card-1.png" }}
{{ with .Err }}
{{ warnf "%s" . }}
{{ else }}
@@ -49,22 +56,22 @@ Note that if you do not handle `.Err` yourself, Hugo will fail the build the fir
### Remote Options
-When fetching a remote `Resource`, `resources.Get` takes an optional options map as the last argument, e.g.:
+When fetching a remote `Resource`, `resources.GetRemote` takes an optional options map as the last argument, e.g.:
```go-html-template
-{{ $resource := resources.Get "https://example.org/api" (dict "headers" (dict "Authorization" "Bearer abcd")) }}
+{{ $resource := resources.GetRemote "https://example.org/api" (dict "headers" (dict "Authorization" "Bearer abcd")) }}
```
If you need multiple values for the same header key, use a slice:
```go-html-template
-{{ $resource := resources.Get "https://example.org/api" (dict "headers" (dict "X-List" (slice "a" "b" "c"))) }}
+{{ $resource := resources.GetRemote "https://example.org/api" (dict "headers" (dict "X-List" (slice "a" "b" "c"))) }}
```
You can also change the request method and set the request body:
```go-html-template
-{{ $postResponse := resources.Get "https://example.org/api" (dict
+{{ $postResponse := resources.GetRemote "https://example.org/api" (dict
"method" "post"
"body" `{"complete": true}`
"headers" (dict
@@ -75,16 +82,15 @@ You can also change the request method and set the request body:
### Caching of Remote Resources
-Remote resources fetched with `resources.Get` will be cached on disk. See [Configure File Caches](/getting-started/configuration/#configure-file-caches) for details.
+Remote resources fetched with `resources.GetRemote` will be cached on disk. See [Configure File Caches](/getting-started/configuration/#configure-file-caches) for details.
## Asset directory
Asset files must be stored in the asset directory. This is `/assets` by default, but can be configured via the configuration file's `assetDir` key.
-
### Asset Publishing
-Assets will only be published (to `/public`) if `.Permalink` or `.RelPermalink` is used. You can use `.Content` to inline the asset.
+Hugo publishes assets to the to the `publishDir` (typically `public`) when you invoke `.Permalink`, `.RelPermalink`, or `.Publish`. You can use `.Content` to inline the asset.
## Go Pipes
diff --git a/docs/content/en/news/2021-12-17-no-more-releasenotes.md b/docs/content/en/news/2021-12-17-no-more-releasenotes.md
new file mode 100644
index 000000000..38bd75357
--- /dev/null
+++ b/docs/content/en/news/2021-12-17-no-more-releasenotes.md
@@ -0,0 +1,10 @@
+---
+title: "Release Notes now on GitHub Only"
+date: 2021-12-17T12:22:47+01:00
+slug: "no-more-releasenotes-here"
+description: "Hugo Release Notes now gets released on GitHub Only"
+
+---
+
+For details about release notes, you need to go here: https://github.com/gohugoio/hugo/releases -- see this for an Atom feed: https://github.com/gohugoio/hugo/releases.atom
+
diff --git a/docs/content/en/news/2021/0.91.2-relnotes/featured.png b/docs/content/en/news/2021/0.91.2-relnotes/featured.png
new file mode 100644
index 000000000..fddcb22eb
--- /dev/null
+++ b/docs/content/en/news/2021/0.91.2-relnotes/featured.png
Binary files differ
diff --git a/docs/content/en/news/2021/0.91.2-relnotes/index.md b/docs/content/en/news/2021/0.91.2-relnotes/index.md
new file mode 100644
index 000000000..03654bf28
--- /dev/null
+++ b/docs/content/en/news/2021/0.91.2-relnotes/index.md
@@ -0,0 +1,9 @@
+---
+title: "Fixes the “Stuck on Build” Bug"
+description: "Hugo 0.91.2 is the last release before Christmas!"
+date: 2021-12-23T17:47:41+01:00
+---
+
+Read the full change log on [GitHub](https://github.com/gohugoio/hugo/releases/tag/v0.91.2).
+
+**Merry Christmas to all of you!**
diff --git a/docs/content/en/templates/data-templates.md b/docs/content/en/templates/data-templates.md
index 441cc2f10..cb3de7f9f 100644
--- a/docs/content/en/templates/data-templates.md
+++ b/docs/content/en/templates/data-templates.md
@@ -53,8 +53,8 @@ The example below is a bit contrived, but it illustrates the flexibility of data
{{< code-toggle file="jacopastorius" >}}
discography = [
-"1974 – Modern American Music … Period! The Criteria Sessions",
-"1974 – Jaco",
+"1974 - Modern American Music … Period! The Criteria Sessions",
+"1974 - Jaco",
"1976 - Jaco Pastorius",
"1981 - Word of Mouth",
"1981 - The Birthday Concert (released in 1995)",
diff --git a/docs/content/en/variables/files.md b/docs/content/en/variables/files.md
index 1769fa688..d8f3daece 100644
--- a/docs/content/en/variables/files.md
+++ b/docs/content/en/variables/files.md
@@ -40,7 +40,7 @@ The `.File` object contains the following fields:
: the filename without extension (e.g., `foo.en`)
.File.Ext
-: the file extension of the content file (e.g., `md`); this can also be called using `.File.Extension` as well. Note that it is *only* the extension without `.`.
+: the file extension of the content file (e.g., `md`).
.File.Lang
: the language associated with the given file if Hugo's [Multilingual features][multilingual] are enabled (e.g., `en`)
diff --git a/docs/content/en/variables/git.md b/docs/content/en/variables/git.md
index 59ee9ac88..58a285fd9 100644
--- a/docs/content/en/variables/git.md
+++ b/docs/content/en/variables/git.md
@@ -37,10 +37,10 @@ The `GitInfo` object contains the following fields:
: the abbreviated commit hash (e.g., `866cbcc`)
.AuthorName
-: the author's name, respecting `.mailmap`
+: the author's name, respecting [`.mailmap`](https://git-scm.com/docs/gitmailmap)
.AuthorEmail
-: the author's email address, respecting `.mailmap`
+: the author's email address, respecting [`.mailmap`](https://git-scm.com/docs/gitmailmap)
.AuthorDate
: the author date
diff --git a/docs/content/en/variables/page.md b/docs/content/en/variables/page.md
index 4ba4d3d91..79b1447f8 100644
--- a/docs/content/en/variables/page.md
+++ b/docs/content/en/variables/page.md
@@ -33,6 +33,9 @@ See [`.Scratch`](/functions/scratch/) for page-scoped, writable variables.
.Aliases
: aliases of this page
+.BundleType
+: the [bundle] type: `leaf`, `branch`, or an empty string if the page is not a bundle.
+
.Content
: the content itself, defined below the front matter.
@@ -305,3 +308,4 @@ 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" >}}