From 8c9269c9a2855b018e82fc3b6bc999122355d835 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Wed, 15 Mar 2017 22:42:05 -0400 Subject: [PATCH] General cleanup + refactor --- core/core-editor.el | 3 +-- core/core-projects.el | 6 ++++-- modules/ui/doom-dashboard/config.el | 1 + modules/ui/doom/config.el | 5 +++-- 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/core/core-editor.el b/core/core-editor.el index 283af42f9..a6d1ac425 100644 --- a/core/core-editor.el +++ b/core/core-editor.el @@ -71,8 +71,7 @@ (defun doom|dont-kill-scratch-buffer () (if (not (eq (buffer-name) "*scratch*")) t - (bury-buffer) - nil)) + (ignore (bury-buffer)))) (add-hook 'kill-buffer-query-functions 'doom|dont-kill-scratch-buffer) ;; enabled by default in Emacs 25+. No thanks. diff --git a/core/core-projects.el b/core/core-projects.el index c125bfa33..da2eda140 100644 --- a/core/core-projects.el +++ b/core/core-projects.el @@ -99,8 +99,10 @@ see if NAME should be activated. :modes MODES -- if buffers are derived from MODES (one or a list of symbols). - :files FILES -- if project contains FILES (relative to project root); takes a - solitary string or a form comprised of (and ...) and/or (or ...) forms. + :files FILES -- if project contains FILES; takes a solitary string or a form + comprised of (and ...) and/or (or ...) forms. Each path is relative to the + project root, however, if prefixed with a '.' or '..', it is relative to the + current buffer. :match REGEXP -- if file name matches REGEXP diff --git a/modules/ui/doom-dashboard/config.el b/modules/ui/doom-dashboard/config.el index f9d129223..231d49906 100644 --- a/modules/ui/doom-dashboard/config.el +++ b/modules/ui/doom-dashboard/config.el @@ -1,3 +1,4 @@ +;;; ui/doom-dashboard/config.el (defvar +doom-dashboard-name " *doom*" "TODO") diff --git a/modules/ui/doom/config.el b/modules/ui/doom/config.el index ec1b7132e..49c1f45f0 100644 --- a/modules/ui/doom/config.el +++ b/modules/ui/doom/config.el @@ -53,15 +53,16 @@ (push (cons 'background-color (face-background 'default)) default-frame-alist) (push (cons 'foreground-color (face-foreground 'default)) default-frame-alist) - ;; brighter real buffers (defun +doom|buffer-mode-on () + "Enable `doom-buffer-mode' in buffers that are real (see +`doom-real-buffer-p')." (when (and (not doom-buffer-mode) (doom-real-buffer-p)) (doom-buffer-mode +1))) (add-hook 'after-change-major-mode-hook '+doom|buffer-mode-on) - ;; Popup buffers should always be dimmed (defun +doom|buffer-mode-off () + "Disable `doom-buffer-mode' in popup buffers." (when (and doom-buffer-mode (not (get-buffer-window-list))) (doom-buffer-mode -1)))