Skip to content
Find file
Fetching contributors…
Cannot retrieve contributors at this time
10 lines (8 sloc) 314 Bytes
(defun bury-scratch ()
"Bury scratch buffer and return nil. Intended to be added to
kill-buffer-query-functions in order to prevent the scratch
buffer being killed."
(if (string= (buffer-name) "*scratch*")
(progn (bury-buffer) nil)
(add-to-list 'kill-buffer-query-functions 'bury-scratch)
Something went wrong with that request. Please try again.