From deb61b6ee912f9c66277244c5560dc2419d145ee Mon Sep 17 00:00:00 2001 From: James Kruth Date: Wed, 4 Jan 2023 00:48:38 -0500 Subject: [PATCH] Set `packge-user-dir` in early-init.el In Emacs 27 and later `package-initialize` is called automatically after `early-init.el` but before `init.el`. This change allows that call to actually work with the user's packages. I left the assignment in the init code for Emacs versions less than 27 that don't support `early-init.el`. --- chemacs.el | 1 + 1 file changed, 1 insertion(+) diff --git a/chemacs.el b/chemacs.el index eaccf6e..90bca07 100644 --- a/chemacs.el +++ b/chemacs.el @@ -146,6 +146,7 @@ selected profile (if any)." (defun chemacs-load-user-early-init () (let ((early-init-file (expand-file-name "early-init.el" user-emacs-directory))) + (setq package-user-dir (expand-file-name "elpa" user-emacs-directory)) (load early-init-file t t))) (defun chemacs-load-user-init ()