vermut / intellij-ansible

YAML/Ansible support with Jinja2 tags / IntelliJ IDEA
https://plugins.jetbrains.com/plugin/7792
Other
205 stars 29 forks source link

Jinja2 Notation with Loops #71

Closed nuarhu closed 7 years ago

nuarhu commented 7 years ago

Hi there,

this is a bit like #4 but it has been closed and the notation is using pipes so I'm creating a new issue for it. Rather then a fix I would be just fine to know if:

Current syntax which just makes everything after it go completely red and breaks all validation:

        url:
{% for host in groups['xxx'] %}
            - "http://{{ hostvars[host].do_private_ip_address }}:{{ port }}/"
{% endfor %}

Thanks for your work!

vermut commented 7 years ago
        url:
# This makes it YAML comment but Jinja still executed {% for host in groups['xxx'] %}
            - "http://{{ hostvars[host].do_private_ip_address }}:{{ port }}/"
# {% endfor %}