emacs: Autoload hooks instead of putting them in 'guix-init'.

* emacs/guix-init.el: Move adding hooks to...
* emacs/guix-build-log.el: ... here.
* emacs/guix-devel.el: ... and here.
This commit is contained in:
Alex Kost 2016-02-08 20:18:25 +03:00
parent 5dccaffe64
commit 19a9c6f47c
3 changed files with 6 additions and 3 deletions

View File

@ -366,6 +366,9 @@ programmatically using hooks:
(guix-find-file-or-url file-or-url)
(guix-build-log-mode))
;;;###autoload
(add-hook 'shell-mode-hook 'guix-build-log-minor-mode-activate-maybe)
;;;###autoload
(add-to-list 'auto-mode-alist
;; Regexp for log files (usually placed in /var/log/guix/...)

View File

@ -364,6 +364,9 @@ bindings:
(when guix-devel-activate-mode
(guix-devel-mode)))
;;;###autoload
(add-hook 'scheme-mode-hook 'guix-devel-activate-mode-maybe)
(defvar guix-devel-emacs-font-lock-keywords
(eval-when-compile

View File

@ -1,7 +1,4 @@
(require 'guix-autoloads)
(require 'guix-emacs)
(add-hook 'scheme-mode-hook 'guix-devel-activate-mode-maybe)
(add-hook 'shell-mode-hook 'guix-build-log-minor-mode-activate-maybe)
(provide 'guix-init)