fix: stop possible from-file, type module collision in template

This commit is contained in:
Gerald Pinder 2024-01-03 23:50:08 -05:00
parent d663b7574b
commit dfb315447c

View file

@ -9,8 +9,7 @@
{%- else %} {%- else %}
RUN chmod +x /tmp/modules/{{ type }}/{{ type }}.sh && source /tmp/exports.sh && /tmp/modules/{{ type }}/{{ type }}.sh '{{ self::print_module_context(module) }}' RUN chmod +x /tmp/modules/{{ type }}/{{ type }}.sh && source /tmp/exports.sh && /tmp/modules/{{ type }}/{{ type }}.sh '{{ self::print_module_context(module) }}'
{%- endif %} {%- endif %}
{%- endif %} {%- else if let Some(from_file) = module.from_file %}
{%- if let Some(from_file) = module.from_file %}
{{ self::get_module_from_file(from_file).render().unwrap() }} {{ self::get_module_from_file(from_file).render().unwrap() }}
{%- endif %} {%- endif %}
{%- endfor %} {%- endfor %}