Add admonition note to getenv function

This commit is contained in:
Ryan Watters 2017-06-22 11:39:43 -05:00 committed by Anthony Fok
parent 9305be17ca
commit 52aedacd2b
2 changed files with 7 additions and 4 deletions

View File

@ -24,9 +24,12 @@ aliases: []
Takes a string containing the name of the variable as input. Returns Takes a string containing the name of the variable as input. Returns
an empty string if the variable is not set, otherwise returns the an empty string if the variable is not set, otherwise returns the
value of the variable. Note that in Unix-like environments, the value of the variable.
variable must also be exported in order to be seen by `hugo`.
``` ```
{{ getenv "HOME" }} {{ getenv "HOME" }}
``` ```
{{% note %}}
In Unix-like environments, the variable must also be exported in order to be seen by `hugo`.
{{% /note %}}

View File

@ -56,7 +56,7 @@ By default, hugo will create new content files with at least `date`, `title` (in
used by Hugo when generating your website. You can write these files in YAML, JSON, or TOML format. In addition to the files you add to this folder, you can also create [data templates][] that pull from dynamic content. used by Hugo when generating your website. You can write these files in YAML, JSON, or TOML format. In addition to the files you add to this folder, you can also create [data templates][] that pull from dynamic content.
[`layouts`][] [`layouts`][]
: stores templates in the form of `.html` files that specify how views of your content will be rendered into a static website. Templates include [list pages][lists], your [homepage][], [taxonomy templates][], [partials][], [single page templates][singles], and more. : Stores templates in the form of `.html` files that specify how views of your content will be rendered into a static website. Templates include [list pages][lists], your [homepage][], [taxonomy templates][], [partials][], [single page templates][singles], and more.
`static` `static`
: stores all the static content for your future website: images, CSS, JavaScript, etc. When Hugo builds your site, all assets inside your static directory are copied over as-is. A good example of using the `static` folder is for [verifying site ownership on Google Search Console][searchconsole], where you want Hugo to copy over a complete HTML file without modifying its content. : stores all the static content for your future website: images, CSS, JavaScript, etc. When Hugo builds your site, all assets inside your static directory are copied over as-is. A good example of using the `static` folder is for [verifying site ownership on Google Search Console][searchconsole], where you want Hugo to copy over a complete HTML file without modifying its content.
@ -72,7 +72,7 @@ Hugo does not currently ship with an asset pipeline ([#3207](https://github.com/
[content section]: /content-management/sections/ [content section]: /content-management/sections/
[content types]: /content-management/types/ [content types]: /content-management/types/
[data templates]: /templates/data-templates/ [data templates]: /templates/data-templates/
[homepage]: /templates/homepage-templates/ [homepage]: /templates/homepage/
[`layouts`]: /templates/ [`layouts`]: /templates/
[lists]: /templates/list/ [lists]: /templates/list/
[pagevars]: /variables/page/ [pagevars]: /variables/page/