diff --git a/lisp/cli/compile.el b/lisp/cli/compile.el index 5dd251d45..88cfed2d9 100644 --- a/lisp/cli/compile.el +++ b/lisp/cli/compile.el @@ -199,7 +199,7 @@ module. This does not include your byte-compiled, third party packages.'" in (append (doom-glob doom-emacs-dir "*.elc") (doom-files-in doom-user-dir :match "\\.elc$" :depth 1) (doom-files-in doom-core-dir :match "\\.elc$") - (doom-files-in doom-modules-dirs :match "\\.elc$" :depth 4)) + (doom-files-in doom-module-load-path :match "\\.elc$" :depth 4)) if (file-exists-p path) do (delete-file path) and do (print! (success "\033[KDeleted %s%s") (relpath path) esc) diff --git a/lisp/doom-modules.el b/lisp/doom-modules.el index cf9ebe471..24e8f70f8 100644 --- a/lisp/doom-modules.el +++ b/lisp/doom-modules.el @@ -267,7 +267,7 @@ If PLIST consists of a single nil, the module is purged from memory instead." PATHS-OR-ALL can either be a non-nil value or a list of directories. If given a list of directories, return a list of module keys for all modules present -underneath it. If non-nil, return the same, but search `doom-modules-dirs' +underneath it. If non-nil, return the same, but search `doom-module-load-path' (includes :core and :user). Modules that are enabled are sorted first by their :depth, followed by disabled modules in lexicographical order (unless a :depth is specified in their .doommodule). @@ -279,7 +279,7 @@ configdepth. See `doom-module-set' for details." (append (seq-remove #'cdr (doom-module-list nil initorder?)) (doom-files-in (if (listp paths-or-all) paths-or-all - doom-modules-dirs) + doom-modules-load-path) :map #'doom-module-from-path :type 'dirs :mindepth 1 @@ -309,7 +309,7 @@ If the category isn't enabled this returns nil. For finding disabled modules use path))) (defun doom-module-locate-path (category &optional module file) - "Searches `doom-modules-dirs' to find the path to a module. + "Searches `doom-module-load-path' to find the path to a module. CATEGORY is a keyword (e.g. :lang) and MODULE is a symbol (e.g. 'python). FILE is a string that will be appended to the resulting path. If no path exists, this @@ -325,8 +325,8 @@ returns nil, otherwise an absolute path." (if file ;; PERF: locate-file-internal is a little faster for finding files, ;; but its interface for finding directories is clumsy. - (locate-file-internal path doom-modules-dirs '("" ".elc" ".el")) - (cl-loop for default-directory in doom-modules-dirs + (locate-file-internal path doom-module-load-path '("" ".elc" ".el")) + (cl-loop for default-directory in doom-module-load-path if (file-exists-p path) return (expand-file-name path))))))) diff --git a/lisp/doom-profiles.el b/lisp/doom-profiles.el index 668eccb24..94dd3dd09 100644 --- a/lisp/doom-profiles.el +++ b/lisp/doom-profiles.el @@ -439,7 +439,7 @@ Defaults to the profile at `doom-profile-default'." (doom-autoloads--scan (append (doom-glob doom-core-dir "lib/*.el") (cl-loop for dir - in (append (doom-module-load-path doom-modules-dirs) + in (append (doom-module-load-path) (list doom-user-dir)) if (doom-glob dir "autoload.el") collect (car it) if (doom-glob dir "autoload/*.el") append it) diff --git a/lisp/lib/autoloads.el b/lisp/lib/autoloads.el index 958db1c8d..9dec16be5 100644 --- a/lisp/lib/autoloads.el +++ b/lisp/lib/autoloads.el @@ -186,7 +186,7 @@ non-nil, treat FILES as pre-generated autoload files instead." (let ((load-file-name file) (load-path (append (list doom-user-dir) - doom-modules-dirs + doom-module-load-path load-path))) (condition-case _ (while t diff --git a/lisp/lib/debug.el b/lisp/lib/debug.el index d43d593f7..741e59ff3 100644 --- a/lisp/lib/debug.el +++ b/lisp/lib/debug.el @@ -301,7 +301,7 @@ ready to be pasted in a bug report on github." 'compiled-user-config) (if (doom-files-in doom-core-dir :type 'files :match "\\.elc$") 'compiled-core) - (if (doom-files-in doom-modules-dirs :type 'files :match "\\.elc$") + (if (doom-files-in doom-module-load-path :type 'files :match "\\.elc$") 'compiled-modules))))) (custom ,@(when (and (stringp custom-file)