Hi Everyone,
I created a directory called: “staging” inside my: “config” folder. The documentation says that when Hugo is run without any flags its environment defaults to: “production”, when it is run with: Hugo server the environment is: “development”.
I would like to check what kind of environment is currently in context, for example:
Hugo --environment staging
How can I check if it is “staging” or “production”?
Using: {{ if eq (getenv “HUGO_ENV”) “production” -}} does nto work, for I guess it is for checking system environment variables.
Thanks for help in advance,
Pawel