commit 8aaa57a573e5092ac0e4eefc5c03b7082dff4495
parent 19e743c7e4be5111775b9bc4d1e2ceacb12cc3c9
Author: Benno Schulenberg <bensberg@telfort.nl>
Date: Tue, 30 Nov 2021 10:24:15 +0100
syntax: default: colorize dates, URLs, and nano's release motto
And change the color for control codes, to be more visible.
Diffstat:
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/syntax/default.nanorc b/syntax/default.nanorc
@@ -10,14 +10,21 @@ color cyan "^[[:blank:]]*#.*"
# Spaces in front of tabs.
color ,red " + +"
-# Nano's name, including version.
-color brightred "(GNU )?[Nn]ano [1-5]\.[0-9][-.[:alnum:]]*\>"
+# Nano's release motto, then name plus version.
+color italic,lime "\<[Nn]ano [1-6]\.[0-9][-.[:alnum:]]* "[^"]+""
+color brightred "\<(GNU )?[Nn]ano [1-6]\.[0-9][-.[:alnum:]]*\>"
+
+# Dates
+color latte "\<[12][0-9]{3}\.(0[1-9]|1[012])\.(0[1-9]|[12][0-9]|3[01])\>"
# Email addresses.
color magenta "<[[:alnum:].%_+-]+@[[:alnum:].-]+\.[[:alpha:]]{2,}>"
+# URLs.
+color lightblue "\<https?://\S+\.\S+[^[:space:],.)]"
+
# Bracketed captions in certain config files.
color brightgreen "^\[[^][]+\]$"
# Control codes.
-color latte "[[:cntrl:]]"
+color orange "[[:cntrl:]]"