Further init.el reorganisation

This commit is contained in:
Wojciech Kozlowski 2017-08-24 22:41:18 +01:00
parent 1a1399a905
commit 6aa38dfce2

50
init.el
View File

@ -13,11 +13,6 @@
(let ((gc-cons-threshold most-positive-fixnum))
;; --------------------------------------------------------------------------
;; Change file in which custom variable changes are saved.
;; --------------------------------------------------------------------------
(setq custom-file "~/.emacs.d/custom.el")
;; --------------------------------------------------------------------------
;; Visual configuration.
;; --------------------------------------------------------------------------
@ -59,6 +54,21 @@
(add-to-list 'custom-theme-load-path "~/.emacs.d/themes/")
(load-theme 'havoc t) ;; Load personal theme
;; --------------------------------------------------------------------------
;; Change file in which custom variable changes are saved.
;; --------------------------------------------------------------------------
(setq custom-file "~/.emacs.d/custom.el")
;; *********************************************************************** ;;
;; ;;
;; ;;
;; Visual configuration must come before this point so that the frame can ;;
;; be set up before before time consuming package management. ;;
;; ;;
;; ;;
;; *********************************************************************** ;;
;; --------------------------------------------------------------------------
;; Package configuration.
;; --------------------------------------------------------------------------
@ -89,6 +99,22 @@
"IndianRed3"
"IndianRed4"))
;; *********************************************************************** ;;
;; ;;
;; ;;
;; Any further non-package specific configuration should be set below this ;;
;; point so that it does not get overridden by package configuration. ;;
;; ;;
;; ;;
;; *********************************************************************** ;;
;; --------------------------------------------------------------------------
;; Load any custom variables.
;; --------------------------------------------------------------------------
(when (file-exists-p custom-file)
(load custom-file))
;; --------------------------------------------------------------------------
;; Formatting
;; --------------------------------------------------------------------------
@ -137,14 +163,14 @@
;; http://bling.github.io/blog/2016/01/18/why-are-you-changing-gc-cons-threshold/
;; --------------------------------------------------------------------------
(defun my-minibuffer-setup-hook ()
(defun minibuffer-gc-setup-hook ()
(setq gc-cons-threshold most-positive-fixnum))
(defun my-minibuffer-exit-hook ()
(defun minibuffer-gc-exit-hook ()
(setq gc-cons-threshold 800000))
(add-hook 'minibuffer-setup-hook #'my-minibuffer-setup-hook)
(add-hook 'minibuffer-exit-hook #'my-minibuffer-exit-hook)
(add-hook 'minibuffer-setup-hook #'minibuffer-gc-setup-hook)
(add-hook 'minibuffer-exit-hook #'minibuffer-gc-exit-hook)
;; --------------------------------------------------------------------------
;; Increase recursion limits.
@ -152,10 +178,4 @@
(setq-default max-specpdl-size 20000) ;; ~15x original value
(setq-default max-lisp-eval-depth 24000) ;; 30x orignal value
;; --------------------------------------------------------------------------
;; Load any custom variables.
;; --------------------------------------------------------------------------
(when (file-exists-p custom-file)
(load custom-file))
) ;; Reset garbage collection settings.