You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Have you therefore considered providing a more powerful templating language like the popular jinja2 as an alternative? I am aware this would introduce an additional python dependency, but right now I can't do many things in the template I would like to do because of the limitations of Go Template...
The text was updated successfully, but these errors were encountered:
As has been pointed out, the specific use case I gave is doable thanks to various additions of docker-gen for the available functions.
Still, I wonder if some templating engine that is both more popular and has a richer set of known default functions for people might at least be worth a consideration? If it's feasible at all to add it as an alternative of course..
fdintino
added a commit
to fdintino/docker-gen
that referenced
this issue
Oct 1, 2017
Go Template'ing seems to be limited and makes some rather basic logical flows impossible or very hard to pull off, see here why: golang/go#14992
While in other templating languages the same logical flow isn't trivially doable either, they usually provide possible workarounds that allow a logical flow as in the link above (for example in jinja2: http://stackoverflow.com/questions/4870346/can-a-jinja-variables-scope-extend-beyond-in-an-inner-block ).
Have you therefore considered providing a more powerful templating language like the popular jinja2 as an alternative? I am aware this would introduce an additional python dependency, but right now I can't do many things in the template I would like to do because of the limitations of Go Template...
The text was updated successfully, but these errors were encountered: