Thanks. but,

On Wed, May 2, 2018 at 11:27 AM, Burak Serdar wrote:

> On Wed, May 2, 2018 at 9:16 AM, Tong Sun wrote:
> >
> >
> >
> >  // now
> >  env := make(map[string]string)
> >  for _, e := range os.Environ() {
> >  sep := strings.Index(e, "=")
> >  env[e[0:sep]] = e[sep+1:]
> >  }
> >  // how to *add *env *into data* as ENV so that it can be accessed
> within
>
> args:=map[string]interface{}{"ENV":env}
> generic(templateStr,args)
>

It looks to me that the above code just pass env (only) to generic, instead
of *adding * into data.


>
> > template,
> >  // e.g., {{.ENV.SHELL}}?
> > }
> >
> >
> >
> > Thanks for your help!
> >
> >
> > --
> > You received this message because you are subscribed to the Google Groups
> > "golang-nuts" group.
> > To unsubscribe from this group and stop receiving emails from it, send an
> > email to golang-nuts+unsubscr...@googlegroups.com.
> > For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to