From b8c2ca53cb586fb91b0a7b6fd749b7180a82cd4a Mon Sep 17 00:00:00 2001 From: noa@gaiwan.org Date: Sat, 15 Jun 2024 00:40:42 +0000 Subject: Put a quote in the scratch buffer --- emacs/init.el | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'emacs') diff --git a/emacs/init.el b/emacs/init.el index dcd15d5..02e2118 100644 --- a/emacs/init.el +++ b/emacs/init.el @@ -870,3 +870,16 @@ The misspelled word is taken from OVERLAY. WORD is the corrected word." (use-package anzu :ensure t) (global-set-key [remap query-replace] 'anzu-query-replace) (global-set-key [remap query-replace-regexp] 'anzu-query-replace-regexp) + +;; Put a quote in the scratch buffer + +(setopt cookie-file "~/data/quotes") + +(setopt initial-scratch-message + (concat (with-temp-buffer + (emacs-lisp-mode) + (insert (cookie cookie-file)) + (mark-whole-buffer) + (comment-region (mark) (point)) + (buffer-substring (mark) (point))) + "\n\n")) -- cgit 1.4.1-2-gfad0