Skip to content

Commit

Permalink
Document HUGO_MEMORYLIMIT
Browse files Browse the repository at this point in the history
  • Loading branch information
jmooring committed Feb 12, 2024
1 parent 89114bb commit 2a623ff
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 2 deletions.
18 changes: 17 additions & 1 deletion content/en/getting-started/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -633,8 +633,24 @@ none

## Configuration environment variables

DART_SASS_BINARY
: (`string`) The absolute path to the Dart Sass executable. By default, Hugo searches for the executable in each of the paths in the `PATH` environment variable.

HUGO_ENVIRONMENT
: (`string`) Overrides the default [environment], typically one of `development`, `staging`, or `production`.

[environment]: /getting-started/glossary/#environment

HUGO_FILE_LOG_FORMAT
: (`string`) A format string for the file path, line number, and column number displayed when reporting errors, or when calling the `Position` method from a shortcode or Markdown render hook. Valid tokens are `:file`, `:line`, and `:col`. Default is `:file::line::col`.

{{< new-in 0.123.0 >}}

HUGO_MEMORYLIMIT
: (`int`) The maximum amount of system memory, in gigabytes, that Hugo can use while rendering your site. Default is 25% of total system memory.

HUGO_NUMWORKERMULTIPLIER
: Can be set to increase or reduce the number of workers used in parallel processing in Hugo. If not set, the number of logical CPUs will be used.
: (`int`) The number of workers used in parallel processing. Default is the number of logical CPUs.

## Configure with environment variables

Expand Down
2 changes: 1 addition & 1 deletion content/en/getting-started/glossary.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ A member of a slice or array.

Typically one of `development`, `staging`, or `production`, each environment may exhibit different behavior depending on configuration and template logic. For example, in a production environment you might minify and fingerprint CSS, but that probably doesn't make sense in a development environment.

When running the built-in development server with the `hugo server` command, the environment is set to `development`. When building your site with the `hugo` command, the environment is set to `production`. To override the environment value, use the `--environment` command line flag.
When running the built-in development server with the `hugo server` command, the environment is set to `development`. When building your site with the `hugo` command, the environment is set to `production`. To override the environment value, use the `--environment` command line flag or the `HUGO_ENVIRONMENT` environment variable.

To determine the current environment within a template, use the [`hugo.Environment`] function.

Expand Down

0 comments on commit 2a623ff

Please sign in to comment.