emacs: adapt use-package-font-lock-keywords for use-feature
authorAmin Bandali <bandali@gnu.org>
Sat, 31 Aug 2019 05:45:31 +0000 (01:45 -0400)
committerAmin Bandali <bandali@gnu.org>
Sat, 31 Aug 2019 05:45:31 +0000 (01:45 -0400)
.emacs.d/init.el

index 60c73b7..601d8e3 100644 (file)
      :straight nil
      ,@args))
 
+(with-eval-after-load 'use-package-core
+  (let ((upflk (car use-package-font-lock-keywords)))
+    (font-lock-add-keywords
+     'emacs-lisp-mode
+     `((,(replace-regexp-in-string
+          "use-package" "use-feature"
+          (car upflk))
+        ,@(cdr upflk))))))
+
 (with-eval-after-load 'recentf
   (add-to-list 'recentf-exclude
                (expand-file-name "~/.emacs.d/straight/build/")))