diff --git a/modules/config/private/init.el b/modules/config/private/init.el index 596eccca5..e361955fe 100644 --- a/modules/config/private/init.el +++ b/modules/config/private/init.el @@ -7,13 +7,9 @@ "The directory that serves as the root of your external private config for Doom Emacs.") -(defvar +private-modules-path - (expand-file-name "modules/" +private-config-path) - "The path to your private, external modules. This will be symlinked to -external/ in `doom-modules-dir'.") - -(defvar +private-module-prefix "private" - "TODO") +(defvar +private-symlink-path + (expand-file-name "private" doom-modules-dir) + "Where the place the symbolic link to the private modules directory.") ;; Ensure `doom//reload-autoloads', `doom//byte-compile' and ;; `doom-initialize-packages' all include this module in their operations. diff --git a/modules/config/private/packages.el b/modules/config/private/packages.el index e586de54f..0544484ae 100644 --- a/modules/config/private/packages.el +++ b/modules/config/private/packages.el @@ -1,14 +1,14 @@ ;; -*- no-byte-compile: t; -*- ;;; config/private/packages.el -(when (file-directory-p +private-modules-path) - ;; automatically symlinks your private modules to `doom-modules-dir'. - (let ((symlink (expand-file-name +private-module-prefix doom-modules-dir))) - (if (and (file-directory-p symlink) - (not (file-symlink-p symlink))) +(let ((modules-path (expand-file-name "modules/" +private-config-path))) + (when (file-directory-p modules-path) + ;; automatically symlinks your private modules to `doom-modules-dir'. + (if (and (file-directory-p +private-symlink-path) + (not (file-symlink-p +private-symlink-path))) (lwarn "config/private" :warning - "modules/%s already exists; can't create symlink" +private-module-prefix) - (make-symbolic-link +private-modules-path symlink t)))) + "modules/%s already exists; can't create symlink" +private-symlink-path) + (make-symbolic-link modules-path +private-symlink-path t)))) ;; (load (expand-file-name "packages.el" +private-config-path)