From 7741139080a6b00aa4f1846fe7668859e91bec58 Mon Sep 17 00:00:00 2001 From: Alex Kost Date: Fri, 19 Jun 2015 12:31:59 +0300 Subject: emacs: Find autoloads in "guix.d" subdirectories. Co-authored-by: Federico Beffa . * emacs/guix-emacs.el (guix-emacs-find-autoloads-in-directory, guix-emacs-subdirs): New functions. (guix-emacs-find-autoloads): Search for autoloads in "guix.d" subdirectories. (guix-emacs-load-autoloads): Add subdirectories to 'load-path'. * emacs/guix-init.el.in: Do not add guix emacs directory to 'load-path' because it will be done by 'guix-emacs-load-autoloads'. Move requiring 'guix-emacs' from the top-level to a clause for checking for 'guix-package-enable-at-startup'. --- emacs/guix-init.el.in | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'emacs/guix-init.el.in') diff --git a/emacs/guix-init.el.in b/emacs/guix-init.el.in index 4e40d7171a..728bc375c2 100644 --- a/emacs/guix-init.el.in +++ b/emacs/guix-init.el.in @@ -1,5 +1,4 @@ (require 'guix-autoloads) -(require 'guix-emacs) (defvar guix-load-path (replace-regexp-in-string "${prefix}" "@prefix@" "@emacsuidir@") @@ -13,9 +12,8 @@ avoid loading autoloads of Emacs packages installed in :type 'boolean :group 'guix) -(add-to-list 'load-path (guix-emacs-directory)) - (when guix-package-enable-at-startup + (require 'guix-emacs) (guix-emacs-load-autoloads 'all)) (provide 'guix-init) -- cgit v1.2.3