diff --git a/core/core-defuns.el b/core/core-defuns.el index fa11985fa..bd828bdeb 100644 --- a/core/core-defuns.el +++ b/core/core-defuns.el @@ -298,22 +298,25 @@ non-nil." "Reload `load-path' and `custom-theme-load-path', in case you updated cask while emacs was open!" (interactive) - (let ((-load-path - (append (list doom-private-dir doom-core-dir doom-modules-dir doom-packages-dir) - (--subdirs doom-core-dir t) - (--subdirs doom-modules-dir t) - (--subdirs doom-packages-dir) - (--subdirs (expand-file-name (format "../../%s/bootstrap" emacs-version) - doom-packages-dir)) - doom--load-path)) - (-custom-theme-load-path - (append (--subdirs doom-themes-dir t) - custom-theme-load-path))) + (let* ((-packages-path (--subdirs doom-packages-dir)) + (-load-path + (append (list doom-private-dir doom-core-dir doom-modules-dir doom-packages-dir) + (--subdirs doom-core-dir t) + (--subdirs doom-modules-dir t) + -packages-path + (--subdirs (expand-file-name (format "../../%s/bootstrap" emacs-version) + doom-packages-dir)) + doom--load-path)) + (-custom-theme-load-path + (append (--subdirs doom-themes-dir t) + custom-theme-load-path))) (setq load-path -load-path custom-theme-load-path -custom-theme-load-path) (if (called-interactively-p 'interactive) (message "Reloaded!") - (list -load-path -custom-theme-load-path)))) + (list -load-path + -custom-theme-load-path + (mapcar '--subdirs -packages-path))))) (defun doom-reload-autoloads () "Regenerate and reload autoloads.el." diff --git a/core/core-scratch.el b/core/core-scratch.el index 74247b418..5665868d2 100644 --- a/core/core-scratch.el +++ b/core/core-scratch.el @@ -114,7 +114,8 @@ buffer. Without this, it would refuse to split, saying 'too small to split'." "\n\n\n" (propertize (concat (s-center 78 "~ ~") "\n" - (s-center 78 (format "Loaded in %s" (emacs-init-time)))) + (s-center 78 (format "Loaded %d packages in %s" + (length doom-packages) (emacs-init-time)))) 'face 'font-lock-comment-face)) (setq doom--scratch-width width doom--scratch-height height))) diff --git a/core/core.el b/core/core.el index 221ea39cd..9f657dceb 100644 --- a/core/core.el +++ b/core/core.el @@ -156,6 +156,9 @@ major-modes, the process gets killed.") "Initial `load-path', used as a base so we don't clobber it on consecutive reloads.") +(defvar doom-packages '() + "A list of all installed packages. Filled internally; do not edit it!") + ;; Just the bear necessities... ♫ (setq load-path (append (list doom-core-dir) doom--load-path)) @@ -164,7 +167,8 @@ reloads.") (require 'core-defuns) (let ((paths (eval-when-compile (doom-reload)))) (setq load-path (car paths) - custom-theme-load-path (cadr paths))) + custom-theme-load-path (cadr paths) + doom-packages (caddr paths))) ;; Many functions are lazy-loaded. The autoloads.el file contains info on where ;; to find them if they're called. Tries to generate autoloads.el if one isn't