Merge branch 'master' of ssh://git.fudo.org:2222/niten/doom-emacs

This commit is contained in:
peter.selby@bytedance.com 2023-12-04 12:17:13 -08:00
commit f4ad408a00
1 changed files with 11 additions and 10 deletions

View File

@ -162,16 +162,17 @@
(let ((local-dir (if (getenv "DOOM_EMACS_LOCAL_PATH")
(getenv "DOOM_EMACS_LOCAL_PATH")
(expand-file-name ".local/emacs.d/" (getenv "HOME")))))
(let ((configs (filter (lambda (name)
(not (or (string-match "~$" name)
(string-match "^[.]" name))))
(directory-files local-dir))))
(dolist (file configs)
(let ((full-file (expand-file-name file local-dir)))
(if (or (file-regular-p full-file) (file-symlink-p full-file))
(progn (message "Loading file %s" full-file)
(load full-file))
(message "Skipping invalid file %s" full-file))))))
(when (file-exists-p local-dir)
(let ((configs (filter (lambda (name)
(not (or (string-match "~$" name)
(string-match "^[.]" name))))
(directory-files local-dir))))
(dolist (file configs)
(let ((full-file (expand-file-name file local-dir)))
(if (or (file-regular-p full-file) (file-symlink-p full-file))
(progn (message "Loading file %s" full-file)
(load full-file))
(message "Skipping invalid file %s" full-file)))))))
(provide 'config)