Closed ewtoombs closed 9 months ago
Perhaps something like
diff --git a/rc/filetype/mail.kak b/rc/filetype/mail.kak
index 4cbae02a..8f99b2b9 100644
--- a/rc/filetype/mail.kak
+++ b/rc/filetype/mail.kak
@@ -24,5 +24,6 @@ add-highlighter shared/mail group
add-highlighter shared/mail/ regex ^(From|To|Cc|Bcc|Subject|Reply-To|In-Reply-To|References|Date|Message-Id|User-Agent):([^\n]*(?:\n\h+[^\n]+)*)$ 1:keyword 2:attribute
add-highlighter shared/mail/ regex <[^@>]+@.*?> 0:string
add-highlighter shared/mail/ regex ^>.*?$ 0:comment
+add-highlighter shared/mail/ regex ^--\ \n.* 0:comment
}
would be sufficient? I noticed this myself this afternoon while editing patch emails.
Feature
In emails, highlight
--
and all text below it differently, to make it clear it is a signature block.Usecase
Plaintext email signature blocks are separated from the email with
--
.It would be nice if https://github.com/mawww/kakoune/blob/master/rc/filetype/mail.kak automatically found this marker and highlighted the signature differently. This way, if there is a typo in the
--
, there will be a notable lack of separate highlighting, helping reveal the mistake.This would also be nice for reading already-written plaintext .eml files in kakoune.