4fe8d78dbb
This is the first in a series of commits for refactoring my configuration to make use of jwiegley's use-package. In the previous layout of the configuration there were some questions around what settings go into which file, but in the end it is all just related to which packages are being configured (besides settings related to global Emacs behaviour). This commit introduces use-package forms for all currently used packages (which are still installed via Nix, not via package.el) but does not yet clean up the rest of the configuration in a suitable way. Note that this version introduces a bug in which the configuration of telephone line is not correctly initialised after package setup.
36 lines
934 B
EmacsLisp
36 lines
934 B
EmacsLisp
;; Initializes modes I use.
|
|
|
|
(add-hook 'prog-mode-hook 'esk-add-watchwords)
|
|
|
|
;; Use auto-complete as completion at point
|
|
(defun set-auto-complete-as-completion-at-point-function ()
|
|
(setq completion-at-point-functions '(auto-complete)))
|
|
|
|
(add-hook 'auto-complete-mode-hook
|
|
'set-auto-complete-as-completion-at-point-function)
|
|
|
|
;; Enable rainbow-delimiters for all things programming
|
|
(add-hook 'prog-mode-hook 'rainbow-delimiters-mode)
|
|
|
|
;; Enable Paredit & Company in Emacs Lisp mode
|
|
(add-hook 'emacs-lisp-mode-hook 'company-mode)
|
|
|
|
;; Always highlight matching brackets
|
|
(show-paren-mode 1)
|
|
|
|
;; Always auto-close parantheses and other pairs
|
|
;; (replaced by smartparens)
|
|
;; (electric-pair-mode)
|
|
|
|
;; Keep track of recent files
|
|
(recentf-mode)
|
|
|
|
;; Easily navigate sillycased words
|
|
(global-subword-mode 1)
|
|
|
|
;; Transparently open compressed files
|
|
(auto-compression-mode t)
|
|
|
|
;; Show available key chord completions
|
|
|
|
(provide 'modes)
|