From 7371be610b4625e5ec7e93636e78b7aae8aefdfd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Delafond?= Date: Fri, 22 Mar 2019 11:51:29 +0100 Subject: [elisp] Make sure emacs doesn't highlight quoted strings by default Also rationalize highlighting of /^CVE-.+/ lines. --- conf/cvelist.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'conf') diff --git a/conf/cvelist.el b/conf/cvelist.el index 64d9cf8e10..fa8b16c6da 100644 --- a/conf/cvelist.el +++ b/conf/cvelist.el @@ -26,13 +26,13 @@ "Keymap for `debian-cvelist-mode'.") (defvar debian-cvelist-font-lock-keywords - '(("^CVE-[0-9]\\{4\\}-[0-9X]\\{4,7\\}" . font-lock-function-name-face) + '(("^CVE-[0-9]\\{4\\}-[0-9X]\\{4,7\\}" (0 font-lock-function-name-face) ;; face for CVE keyword + ("(\\(.+\\))$" nil nil (1 font-lock-warning-face))) ;; face for the rest of the line ("D[LS]A-[0-9]\\{4,5\\}-[0-9]" . font-lock-function-name-face) ("#[0-9]\\{1,7\\}" . font-lock-type-face) ("^\tNOTE:" . font-lock-comment-delimiter-face) ("^\tTODO:" . font-lock-warning-face) ("^\t\\(RESERVED\\|NOT-FOR-US\\|REJECTED\\)" . font-lock-keyword-face) - ("^CVE-[0-9]\\{4\\}-[0-9X]\\{4,7\\}" "[\\[(]\\(.+?\\).$" nil nil (1 font-lock-variable-name-face)) ("\\" . font-lock-warning-face) ("\\" . font-lock-constant-face)) "Keyword highlighting for `debian-cvelist-mode'") @@ -52,6 +52,7 @@ (define-derived-mode debian-cvelist-mode fundamental-mode "debian-cvelist" "A major mode for editing data/CVE/list in the Debian secure-testing repo." (setq-local font-lock-defaults '(debian-cvelist-font-lock-keywords nil)) + (setq font-lock-keywords-only t) (setq indent-line-function 'debian-cvelist-indent-line)) (provide 'debian-cvelist) -- cgit v1.2.3