From ea93427777b2368a204215469f66a6a9afa7c06f Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Thu, 26 Mar 2015 15:22:21 -0400 Subject: clean up emacs init --- .config/emacs/init.el | 42 +++++++++++++++++++++++++----------------- 1 file changed, 25 insertions(+), 17 deletions(-) diff --git a/.config/emacs/init.el b/.config/emacs/init.el index 5f399a0..eddd0b7 100644 --- a/.config/emacs/init.el +++ b/.config/emacs/init.el @@ -1,4 +1,5 @@ ;; This config requires Emacs 24.4(+?) +;; Hey, Emacs: -*- Indent-tabs-mode: nil -*- ;; Without (advice-add) it should work in older versions of Emacs 24. ;;;; Use XDG-ish locations ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (setq xdg-cache-home (file-name-as-directory (or (getenv "XDG_CACHE_HOME") "~/.cache"))) @@ -88,12 +89,14 @@ (:name dtrt-indent :type elpa ;; Detect indent style for existing files :after (dtrt-indent-mode 1)) (:name page-break-lines :type elpa ;; Display form-feeds pretty - :before (advice-add 'page-break-lines-mode-maybe :override #'page-break-lines-mode) + :before (advice-add 'page-break-lines-mode-maybe + :override #'page-break-lines-mode) :after (global-page-break-lines-mode 1)) (:name smart-tabs-mode :type elpa ;; Indent with tabs, align with spaces :after (progn (smart-tabs-mode 1) - (apply 'smart-tabs-insinuate (mapcar 'car smart-tabs-insinuate-alist)))) + (apply 'smart-tabs-insinuate + (mapcar 'car smart-tabs-insinuate-alist)))) ;; Major modes (:name bison-mode :type elpa) (:name coffee-mode :type elpa @@ -112,23 +115,28 @@ )) ;; What packages el-get should install, both from above, and it's ;; internal list of sources. -(el-get 'sync '(el-get +(el-get 'sync (append + '(el-get) ;; Minor modes - dtrt-indent - page-break-lines - smart-tabs-mode + '(dtrt-indent + page-break-lines + smart-tabs-mode + ) ;; Major modes - ;;apel flim semi wanderlust ; wanderlust is huge, only use on emailing boxes - ;;nxhtml ; nxhtml is invasive, only enable if actively using - bison-mode - coffee-mode - graphviz-dot-mode - haml-mode - markdown-mode - nginx-mode - php-mode-improved - scss-mode - )) + (if (file-exists-p "~/Maildir") ; wanderlust is huge, only use on emailing boxes + '(apel flim semi wanderlust) + '()) + '( + ;;nxhtml ; nxhtml is invasive, only enable if actively using + bison-mode + coffee-mode + graphviz-dot-mode + haml-mode + markdown-mode + nginx-mode + php-mode-improved + scss-mode + ))) ;; Misc. crap -- cgit v1.1-4-g5e80