In batch.xml rem is declared as line comment property. Rule ignore_case="true". Trying to toggle a line like this:
REM copy asdf
results in:
rem REM copy asdf
Desired behaviour: uncomment line.
The problem here is that "lineComment" is defined in PROPS while case-sensitivity is defined per ruleset.
So there is no way (currently) to define that the lineComment string is case insensitive.
My proposal would be to simply treat EVERY lineComment as being case-insensitive.
For this, change in TextToolComments.java
Line 126 from
if(line.length() > 0 && !line.startsWith(lineComment))
to
if(line.length() > 0 && !line.toLowerCase().startsWith(lineComment.toLowerCase()))
and line 172 from
if(line.trim().startsWith(lineComment) && doUncomment)
if(line.trim().toLowerCase().startsWith(lineComment.toLowerCase()) && doUncomment)
Log in to post a comment.
The problem here is that "lineComment" is defined in PROPS while case-sensitivity is defined per ruleset.
So there is no way (currently) to define that the lineComment string is case insensitive.
My proposal would be to simply treat EVERY lineComment as being case-insensitive.
For this, change in TextToolComments.java
Line 126 from
to
and line 172 from
to
Last edit: Skeeve 2017-11-01