Fix doom quickstart not installing packages

If the user had no ~/.doom.d/init.el to begin with, and never reads it
after it's been created (by `doom quickstart`), then Doom can't possibly
know what modules to install packages for, therefore no packages get
installed!
This commit is contained in:
Henrik Lissner 2019-04-09 03:31:05 -04:00
parent d3a12a3914
commit defd60b24b
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395
2 changed files with 7 additions and 4 deletions

View file

@ -59,6 +59,10 @@ packages and regenerates the autoloads file."
(funcall fn))
(print! (green "Done!")))))))
;; In case no init.el was present the first time `doom-initialize-modules' was
;; called in core.el (e.g. on first install)
(doom-initialize-modules)
;; Ask if Emacs.app should be patched
(if (member "--no-env" args)
(print! (yellow "Not generating envvars file, as requested"))

View file

@ -57,11 +57,10 @@ before the user's private module.")
"Loads the init.el in `doom-private-dir' and sets up hooks for a healthy
session of Dooming. Will noop if used more than once, unless FORCE-P is
non-nil."
(when (or force-p (not doom-init-modules-p))
(when (and (or force-p
(not doom-init-modules-p))
(load! "init" doom-private-dir t))
(setq doom-init-modules-p t)
(load! "init" doom-private-dir t)
(unless doom-modules
(setq doom-modules (make-hash-table :test 'equal)))
(maphash (lambda (key plist)
(let ((doom--current-module key)
(doom--current-flags (plist-get plist :flags)))