syntax: nanorc: require whitespace before the start= and end= keywords
Also, drop the unneeded and mistaken 'end=' in the first regex, as a coloring rule with just end="something" is not valid. And drop the requirement for having trailing whitespace or nothing at all, as it does not constitute a useful restriction. Also, fold two regexes together, for economy.master
parent
4d9be13316
commit
d9e42cb274
|
@ -20,13 +20,13 @@ color brightgreen "^[[:blank:]]*(syntax[[:blank:]]+[^[:space:]]+|(formatter|lint
|
||||||
color green "^[[:blank:]]*((un)?(bind|set)|include|syntax|header|magic|comment|formatter|linter|tabgives|extendsyntax)\>"
|
color green "^[[:blank:]]*((un)?(bind|set)|include|syntax|header|magic|comment|formatter|linter|tabgives|extendsyntax)\>"
|
||||||
|
|
||||||
# Strings
|
# Strings
|
||||||
color brightmagenta "([[:blank:]]|(start|end)=)".+"([[:blank:]]|$)"
|
color brightmagenta "[[:blank:]](start=)?".+""
|
||||||
|
|
||||||
# Control codes
|
# Control codes
|
||||||
color bold,pink "[[:cntrl:]]"
|
color bold,pink "[[:cntrl:]]"
|
||||||
|
|
||||||
# Color commands
|
# Color commands
|
||||||
color magenta "^[[:blank:]]*i?color\>" "\<(start|end)="
|
color magenta "^[[:blank:]]*i?color\>|[[:blank:]](start=|end=)"
|
||||||
|
|
||||||
# Comments
|
# Comments
|
||||||
color brightblue "(^|[[:blank:]]+)#.*"
|
color brightblue "(^|[[:blank:]]+)#.*"
|
||||||
|
|
Loading…
Reference in New Issue