summaryrefslogtreecommitdiff
path: root/.emacs.d
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2022-05-02 16:04:21 -0700
committerSean Whitton <spwhitton@spwhitton.name>2022-05-02 16:04:50 -0700
commit1daa281f0586bb78db1169302d9ef84085e7b0ef (patch)
tree80bf25f812b8df36a27ea453859473a92384edc1 /.emacs.d
parente0f02c4b09683bba1ca9df780327157f81ee34e7 (diff)
downloaddotfiles-1daa281f0586bb78db1169302d9ef84085e7b0ef.tar.gz
bind new scratch-buffer command to C-x l
Diffstat (limited to '.emacs.d')
-rw-r--r--.emacs.d/init.el9
1 files changed, 3 insertions, 6 deletions
diff --git a/.emacs.d/init.el b/.emacs.d/init.el
index 38ea56a1..ba908ec1 100644
--- a/.emacs.d/init.el
+++ b/.emacs.d/init.el
@@ -442,12 +442,9 @@ that's something we can determine.")
";; This buffer is for Lisp evaluation.
;; To create a file, visit it with C-x C-f and enter text in its buffer.\n\n")
-(defun spw/switch-to-*scratch* ()
- (interactive)
- (pop-to-buffer "*scratch*")
- (unless (eq major-mode 'lisp-interaction-mode)
- (lisp-interaction-mode)))
-(global-set-key "\C-cl" #'spw/switch-to-*scratch*)
+;; This uses `pop-to-buffer-same-window', so obeys my `display-buffer-alist'
+;; entry for *scratch*.
+(global-set-key "\C-xl" #'scratch-buffer)
(defun spw/paredit-ctl-j ()
"Replacement for `paredit-newline' which does traditional Emacs