Search compressed .el files in load history

On many installations, the .el files that are builtin to emacs are
compressed. We should search these as well.

Signed-off-by: Rudi Grinberg <me@rgrinberg.com>
This commit is contained in:
Rudi Grinberg 2020-10-09 14:28:50 -07:00
parent 1757dd1700
commit b52072ec90

View file

@ -662,6 +662,7 @@ Uses the symbol at point or the current selection, if available."
(doom--help-search (doom--help-search
(cl-loop for (file . _) in (cl-remove-if-not #'stringp load-history :key #'car) (cl-loop for (file . _) in (cl-remove-if-not #'stringp load-history :key #'car)
for filebase = (file-name-sans-extension file) for filebase = (file-name-sans-extension file)
if (file-exists-p! (format "%s.el" filebase)) if (file-exists-p! (or (format "%s.el.gz" filebase)
(format "%s.el" filebase)))
collect it) collect it)
query "Search loaded files: ")) query "Search loaded files: "))