cli/doctor: fix font checks

This commit is contained in:
Henrik Lissner 2019-11-09 20:32:48 -05:00
parent 5c3f7d648d
commit 6c31968a46
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -140,15 +140,15 @@ in."
"/fonts/")) "/fonts/"))
(`darwin "~/Library/Fonts/")) (`darwin "~/Library/Fonts/"))
(require 'all-the-icons nil t)) (require 'all-the-icons nil t))
(dolist (font all-the-icons-font-families) (with-temp-buffer
(if (with-temp-buffer
(insert (cdr (doom-call-process "fc-list"))) (insert (cdr (doom-call-process "fc-list")))
(re-search-backward "Fira" nil t)) (dolist (font all-the-icons-font-names)
(if (save-excursion (re-search-backward font nil t))
(success! "Found font %s" font) (success! "Found font %s" font)
(print! (warn "Warning: couldn't find %S font") font) (print! (warn "Warning: couldn't find %S font") font)
(explain! "You can install it by running `M-x all-the-icons-install-fonts' within Emacs.\n\n" (explain! "You can install it by running `M-x all-the-icons-install-fonts' within Emacs.\n\n"
"This could also mean you've installed them in non-standard locations, in which " "This could also mean you've installed them in non-standard locations, in which "
"case feel free to ignore this warning.")))))) "case feel free to ignore this warning.")))))))
(print! (start "Checking for stale elc files in your DOOMDIR...")) (print! (start "Checking for stale elc files in your DOOMDIR..."))
(when (file-directory-p doom-private-dir) (when (file-directory-p doom-private-dir)