all repos — nixfiles @ dba46b2b648938f18b0ee97b5d121dbeb7fa5dc0

System and user configuration, managed by nix and home-manager

emacs: optimise startup time
Alan Pearce alan@alanpearce.eu
Tue, 28 Mar 2023 21:44:30 +0200
commit

dba46b2b648938f18b0ee97b5d121dbeb7fa5dc0

parent

d3e0e778fed8c4c572f0c41f6b2db6b336e832c8

1 files changed, 12 insertions(+), 5 deletions(-)

jump to
M user/emacs/init.eluser/emacs/init.el
@@ -232,8 +232,11 @@ (use-package hydra
   :defer 2)
 
-(custom-set-variables '(recentf-auto-cleanup 1800))
-(recentf-mode +1)
+(use-package recentf
+  :defer 1
+  :custom (recentf-auto-cleanup 1800)
+  :config (recentf-mode +1))
+
 (use-package savehist
   :init (savehist-mode +1)
   :config (progn
@@ -471,7 +474,7 @@ :commands (company-explicit-action-p)   :config (progn
             (setq company-idle-delay 0.2
                   company-tooltip-align-annotations t
-                  company-show-numbers t
+                  company-show-quick-access t
                   company-dabbrev-downcase nil
                   company-dabbrev-ignore-case nil
                   company-begin-commands '(self-insert-command)
@@ -493,6 +496,7 @@ "S-TAB" #'company-select-previous             "<backtab>" #'company-select-previous))
 
 (use-package all-the-icons
+  :defer t
   :config (setq all-the-icons-color-icons nil))
 
 (defmacro company-set-secondary-backend-for-mode (mode backend)
@@ -552,7 +556,7 @@ ;;;; Auto-reloading
 
 (use-package autorevert
-  :defer 10
+  :defer 1
   :config (progn
             (setq auto-revert-verbose nil
                   auto-revert-use-notify t)
@@ -774,8 +778,10 @@ (use-package racket-mode
   :ghook ('racket-mode-hook #'racket-xp-mode))
 
-(use-package clojure-mode)
+(use-package clojure-mode
+  :defer t)
 (use-package cider
+  :defer t
   :after clojure-mode)
 (use-package rainbow-delimiters
   :ghook ('clojure-mode-hook
@@ -901,6 +907,7 @@ ;;; Projects
 
 (use-package ripgrep
+  :defer 10
   :config (progn
             (setq ripgrep-arguments '("--hidden"))))