Don't error out if no targets for byte-compilation could be found

This commit is contained in:
Henrik Lissner 2018-04-04 08:14:06 -04:00
parent b98e26856d
commit a47d76f5f1
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -797,8 +797,8 @@ If RECOMPILE-P is non-nil, only recompile out-of-date files."
else if (file-exists-p target)
collect target
finally do (setq argv nil)))
(unless compile-targets
(error "No targets to compile"))
(if (not compile-targets)
(message "No targets to compile")
(condition-case ex
(let ((use-package-expand-minimally t))
(push (expand-file-name "init.el" doom-emacs-dir) compile-targets)
@ -837,7 +837,7 @@ If RECOMPILE-P is non-nil, only recompile out-of-date files."
(error-message-string ex)
"Reverting changes...")
(doom//clean-byte-compiled-files)
(message! (green "Finished (nothing was byte-compiled)"))))))))
(message! (green "Finished (nothing was byte-compiled)")))))))))
(defun doom//byte-compile-core (&optional recompile-p)
"Byte compile the core Doom files.