mirror of
https://github.com/doomemacs/doomemacs
synced 2025-08-03 12:27:26 -05:00
Reduce coupling with buffers library and dashboard
This commit is contained in:
@ -260,12 +260,12 @@ project (which may be different across perspective)."
|
|||||||
(defun +doom-dashboard-initial-buffer ()
|
(defun +doom-dashboard-initial-buffer ()
|
||||||
"Returns buffer to display on startup. Designed for `initial-buffer-choice'."
|
"Returns buffer to display on startup. Designed for `initial-buffer-choice'."
|
||||||
(if (string-match-p "^ ?\\*\\(?:scratch\\|server\\)" (buffer-name))
|
(if (string-match-p "^ ?\\*\\(?:scratch\\|server\\)" (buffer-name))
|
||||||
(doom-fallback-buffer)
|
(get-buffer-create +doom-dashboard-name)
|
||||||
(current-buffer)))
|
(current-buffer)))
|
||||||
|
|
||||||
(defun +doom-dashboard-p (buffer)
|
(defun +doom-dashboard-p (buffer)
|
||||||
"Returns t if BUFFER is the dashboard buffer."
|
"Returns t if BUFFER is the dashboard buffer."
|
||||||
(eq buffer (doom-fallback-buffer)))
|
(eq (buffer-name buffer) +doom-dashboard-name))
|
||||||
|
|
||||||
(defun +doom-dashboard-update-pwd (&optional pwd)
|
(defun +doom-dashboard-update-pwd (&optional pwd)
|
||||||
"Update `default-directory' in the Doom dashboard buffer. What it is set to is
|
"Update `default-directory' in the Doom dashboard buffer. What it is set to is
|
||||||
|
Reference in New Issue
Block a user