If a single quoted variable value contains a # character it is interpreted as the start of a comment. All characters following the # on the same line are highlighted as if they are a comment.
Steps to reproduce
Create or edit an .env type file
Add a new line with a variable and value like this
FOOVAR=mybarval
Wrap the value in single-quotes
FOOVAR='mybarval'
Insert a # character mid-way before the end of the value, like this
FOOVAR='mybar#val'
Change quotes from single-quotes to double-quotes , like this
FOOVAR="mybar#val"
What do I expect
The syntax highlighting at step 3 and step 4 and step 5 doesn't change.
What actually happens
The syntax highlight at step 4 changes, showing the end part as if it were a comment. At step 5, when using double-quotes, the syntax highlight appears as normal.
Problem / Motivation
If a single quoted variable value contains a
#
character it is interpreted as the start of a comment. All characters following the#
on the same line are highlighted as if they are a comment.Steps to reproduce
Create or edit an
.env
type fileAdd a new line with a variable and value like this
Wrap the value in single-quotes
Insert a
#
character mid-way before the end of the value, like thisChange quotes from single-quotes to double-quotes , like this
What do I expect
The syntax highlighting at step 3 and step 4 and step 5 doesn't change.
What actually happens
The syntax highlight at step 4 changes, showing the end part as if it were a comment. At step 5, when using double-quotes, the syntax highlight appears as normal.