Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/gohugoio/hugoDocs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2022-04-14 12:29:22 +0300
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2022-04-14 12:29:22 +0300
commitfa7db7c7ee070b3c98a44403a2adb896a3b64f86 (patch)
tree809006eb1e378b5505a6cf8e78be204526c66e8a
parentdd6df54b520740ce9776a087ff69db010a389379 (diff)
parent73e82d911da8f13b6df33482ebfe45203684b41e (diff)
Merge branch 'tempv0.97.0'
-rw-r--r--content/en/commands/hugo_server.md3
-rw-r--r--content/en/content-management/front-matter.md3
-rwxr-xr-xcontent/en/hugo-pipes/introduction.md13
-rw-r--r--data/docs.json15
4 files changed, 32 insertions, 2 deletions
diff --git a/content/en/commands/hugo_server.md b/content/en/commands/hugo_server.md
index 33b95d51c..7d8067386 100644
--- a/content/en/commands/hugo_server.md
+++ b/content/en/commands/hugo_server.md
@@ -64,7 +64,8 @@ hugo server [flags]
--printMemoryUsage print memory usage to screen at intervals
--printPathWarnings print warnings on duplicate target paths etc.
--printUnusedTemplates print warnings on unused templates.
- --renderToDisk render to Destination path (default is render to memory & serve from there)
+ --renderStaticToDisk serve static files from disk and dynamic files from memory
+ --renderToDisk serve all files from disk (default is from memory)
--templateMetrics display metrics about template executions
--templateMetricsHints calculate some improvement hints when combined with --templateMetrics
-t, --theme strings themes to use (located in /themes/THEMENAME/)
diff --git a/content/en/content-management/front-matter.md b/content/en/content-management/front-matter.md
index c068b9006..c915a5f96 100644
--- a/content/en/content-management/front-matter.md
+++ b/content/en/content-management/front-matter.md
@@ -189,6 +189,9 @@ kind
lang
: A Glob pattern matching the Page's language, e.g. "{en,sv}".
+environment
+: A Glob pattern matching the build environment, e.g. "{production,development}"
+
Any of the above can be omitted.
### Example
diff --git a/content/en/hugo-pipes/introduction.md b/content/en/hugo-pipes/introduction.md
index 83d64d1d3..bbafe55b2 100755
--- a/content/en/hugo-pipes/introduction.md
+++ b/content/en/hugo-pipes/introduction.md
@@ -53,6 +53,19 @@ With `resources.GetRemote`, the first argument is a remote URL:
`resources.Get` and `resources.GetRemote` return `nil` if the resource is not found.
+### Caching
+
+By default, Hugo calculates a cache key based on the `URL` and the `options` (e.g. headers) given.
+
+
+{{< new-in "0.97.0" >}} You can override this by setting a `key` in the options map. This can be used to get more fine grained control over how often a remote resource is fetched, e.g.:
+
+
+```go-html-template
+{{ $cacheKey := print $url (now.Format "2006-01-02") }}
+{{ $resource := resource.GetRemote $url (dict "key" $cacheKey) }}
+```
+
### Error Handling
{{< new-in "0.91.0" >}}
diff --git a/data/docs.json b/data/docs.json
index 2440fc930..ddd9e1246 100644
--- a/data/docs.json
+++ b/data/docs.json
@@ -1860,6 +1860,7 @@
"keepNumbers": false
},
"svg": {
+ "keepComments": false,
"precision": 0
},
"xml": {
@@ -4665,6 +4666,12 @@
],
"Examples": []
},
+ "ByType": {
+ "Description": "",
+ "Args": null,
+ "Aliases": null,
+ "Examples": null
+ },
"Concat": {
"Description": "",
"Args": null,
@@ -4694,7 +4701,7 @@
"Examples": null
},
"Get": {
- "Description": "Get locates the filename given in Hugo's assets filesystem and\ncreates a Resource object that can be used for\nfurther transformations.",
+ "Description": "Get locates the filename given in Hugo's assets filesystem\nand creates a Resource object that can be used for further transformations.",
"Args": [
"filename"
],
@@ -4862,6 +4869,12 @@
"Aliases": null,
"Examples": null
},
+ "Current": {
+ "Description": "",
+ "Args": null,
+ "Aliases": null,
+ "Examples": null
+ },
"Data": {
"Description": "",
"Args": null,