Limit adding .info files in `package-user-dir' to Linux

This commit is contained in:
Gerard Vermeulen 2022-12-10 16:56:54 +01:00
parent d63a4d363d
commit da83d11130

View File

@ -937,14 +937,15 @@ looks for files.
#+name: lst:configure-info
#+begin_src emacs-lisp
(with-eval-after-load 'info
;; Make Emacs find ALL "*.info" files in `packages-user-dir'.
;; Make Emacs find ALL "*.info" files in `package-user-dir' on Gentoo Linux.
(when (eq system-type 'gnu/linux)
(dolist (path
(nreverse
(mapcar
(lambda (name)
(expand-file-name (file-name-directory name)))
(directory-files-recursively package-user-dir "\\.info\\'"))))
(add-to-list 'Info-directory-list path nil #'file-equal-p))
(add-to-list 'Info-directory-list path nil #'file-equal-p)))
;; Make Emacs find my "python.info" file.
(add-to-list 'Info-directory-list
(expand-file-name "~/.local/share/info")))