mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-30 22:39:58 +02:00
@@ -16,6 +16,9 @@ package hugo
|
||||
import (
|
||||
"fmt"
|
||||
"html/template"
|
||||
"os"
|
||||
|
||||
"github.com/gohugoio/hugo/config"
|
||||
)
|
||||
|
||||
const (
|
||||
@@ -69,3 +72,9 @@ func NewInfo(environment string) Info {
|
||||
Environment: environment,
|
||||
}
|
||||
}
|
||||
|
||||
func GetExecEnviron(cfg config.Provider) []string {
|
||||
env := os.Environ()
|
||||
config.SetEnvVars(&env, "HUGO_ENVIRONMENT", cfg.GetString("environment"))
|
||||
return env
|
||||
}
|
||||
|
Reference in New Issue
Block a user