diff options
| author | Craig Jennings <c@cjennings.net> | 2025-10-12 11:47:26 -0500 |
|---|---|---|
| committer | Craig Jennings <c@cjennings.net> | 2025-10-12 11:47:26 -0500 |
| commit | 092304d9e0ccc37cc0ddaa9b136457e56a1cac20 (patch) | |
| tree | ea81999b8442246c978b364dd90e8c752af50db5 /modules/wrap-up.el | |
changing repositories
Diffstat (limited to 'modules/wrap-up.el')
| -rw-r--r-- | modules/wrap-up.el | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/modules/wrap-up.el b/modules/wrap-up.el new file mode 100644 index 00000000..f1841189 --- /dev/null +++ b/modules/wrap-up.el @@ -0,0 +1,30 @@ +;;; wrapup --- Functions Run Before Init Completion -*- lexical-binding: t; coding: utf-8; -*- +;; author Craig Jennings <c@cjennings.net> + +;;; Commentary: + +;;; Code: + +;; -------------------------------- Bury Buffers ------------------------------- +;; wait a few seconds then bury compile-related buffers. + +(defun cj/bury-buffers () + "Bury comint and compilation buffers." + (dolist (buf (buffer-list)) + (with-current-buffer buf + (when (or (derived-mode-p 'comint-mode) + (derived-mode-p 'compilation-mode) + (derived-mode-p 'debugger-mode) + (derived-mode-p 'elisp-compile-mode) + (derived-mode-p 'messages-buffer-mode) + ) ;; byte-compilations + (bury-buffer))))) + +(defun cj/bury-buffers-after-delay () + "Run cj/bury-buffers after a delay." + (run-with-timer 1 nil 'cj/bury-buffers)) + +(add-hook 'emacs-startup-hook 'cj/bury-buffers-after-delay) + +(provide 'wrap-up) +;;; wrap-up.el ends here |
