Hi,
is there a pattern for implementing loop similar to python:
for (i,name) in enumerate(list_of_items):
print i, name
when I try to implement it in Jinja I get error (no enumerate is not
available):
{% for (i,name) in enumerate(list_of_items) %}
item{{ i }} = {{ name }}
{%endfor %}
what would be the best way of achieving similar result without
implementing my own filter?
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/9eec2bbe-bb55-43a9-b09b-b5e54989745c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.