1
1

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.
Этот коммит содержится в:
Benno Schulenberg 2021-11-03 17:19:48 +01:00
родитель 4d9be13316
Коммит 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:]]+)#.*"