Skip to content

Matchit: multiline tags and else statement #29

@buzuck

Description

@buzuck

Hi 🙂

When a tag is stretches on multiple lines for readability, it is no longer detected by the plugin matchit/match-up

{% for very_long in dict
   if true and not false %}
[...]
{% endfor %}

I tried to change the variable b:match_words by adding a \_ with no luck though:
'{%[-+]\? *\%(end\)\@!\(\w\+\)\>\_.\{-}%}:{%-\? *end\1\>.\{-}%}'

There is also some improvement that could be done on this plugin. The else statement is not paired with if/endif.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions