From 21727ae3dce8ccea2e342d3b62b5fa67b1b5a936 Mon Sep 17 00:00:00 2001 From: "S. Gilles" Date: Tue, 7 Feb 2017 23:59:36 -0500 Subject: Allow {} to be nested in shell variables This allows lines like : ${FOO:="${bar}/baz"} to be highlighted correctly. --- lua/lexers/bash.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lua/lexers') diff --git a/lua/lexers/bash.lua b/lua/lexers/bash.lua index f8badba..2fa72f2 100644 --- a/lua/lexers/bash.lua +++ b/lua/lexers/bash.lua @@ -46,7 +46,7 @@ local identifier = token(l.IDENTIFIER, l.word) -- Variables. local variable = token(l.VARIABLE, '$' * (S('!#?*@$') + l.digit^1 + l.word + - l.delimited_range('{}', true, true))) + l.delimited_range('{}', true, true, true))) -- Operators. local operator = token(l.OPERATOR, S('=!<>+-/*^&|~.,:;?()[]{}')) -- cgit v1.2.3