Fix bug in run passing content that was too long as args

This commit is contained in:
James Mills 2023-03-20 08:38:05 +10:00
parent 0608690f72
commit bfa4160c6c
No known key found for this signature in database
GPG Key ID: AC4C014F1440EBD6

View File

@ -278,8 +278,10 @@ func run(vars Vars, cmd string, args ...string) (string, error) {
env := []string{"ZS=" + os.Args[0], "ZS_OUTDIR=" + PUBDIR}
env = append(env, os.Environ()...)
for k, v := range vars {
if k != "content" {
env = append(env, "ZS_"+strings.ToUpper(k)+"="+v)
}
}
c.Env = env
c.Stdout = &outbuf
c.Stderr = &errbuf