diff --git a/syntax/python.nanorc b/syntax/python.nanorc index 53643afe..0c60bb76 100644 --- a/syntax/python.nanorc +++ b/syntax/python.nanorc @@ -22,14 +22,15 @@ color brightcyan "\<(exec|print)([[:blank:]]|$)" # Special values. color brightmagenta "\<(False|None|True)\>" -# Single-quoted strings. -color brightgreen "'([^'\]|\\.)+'" -color brightgreen ""([^"\]|\\.)+"" +# Mono-quoted strings. +color brightgreen "'([^'\]|\\.)*'|'''" +color brightgreen ""([^"\]|\\.)*"|"""" +color normal "'''|"""" # Comments. color brightred "(^|[[:blank:]])#.*" # Triple-quoted strings. color brightgreen start="'''([^'),]|$)" end="(^|[^(\])'''" -color brightgreen start="\"\"\"([^"),]|$)" end="(^|[^(\])\"\"\"" +color brightgreen start=""""([^"),]|$)" end="(^|[^(\])"""" # Reminders. color brightwhite,yellow "(FIXME|TODO|XXX)"