diff --git a/syntax/just.vim b/syntax/just.vim index e626b4d..5ed3d3a 100644 --- a/syntax/just.vim +++ b/syntax/just.vim @@ -150,6 +150,7 @@ syn match justExportedAssignment "\v^export%(\s|\\\n)+\h[a-zA-Z0-9_-]*\s*:\=" tr syn match justExport '\v^export%(\s|\\\n)@=' contained syn keyword justConditional if else +syn region justConditionalBraces start="\v\{@1'_9${1}_' ) +conditional_without_indent := if env('SHELL') == '/bin/bash' { +valid_uuid + testing +} else { '' } + test: echo {{something}}{{testing}} diff --git a/tests/cases/tricky.just b/tests/cases/tricky.just index 1d06bc5..0e05e8a 100644 --- a/tests/cases/tricky.just +++ b/tests/cases/tricky.just @@ -29,6 +29,10 @@ not_a_uuid_anymore := replace_regex ( , '_9${1}_' ) +conditional_without_indent := if env('SHELL') == '/bin/bash' { +valid_uuid + testing +} else { '' } + test: echo {{something}}{{testing}}